MCP ExplorerExplorer

Mcp Server Chat History

@FxckingAngelon 9 months ago
1 MIT
FreeCommunity
AI Systems
MCP Server Chat History allows users to manage chat logs efficiently.

Overview

What is Mcp Server Chat History

mcp-server-chat-history is a Model Context Protocol server that provides access to chat history and search functionalities for agentic LLMs and clients.

Use cases

Use cases include retrieving past conversations for analysis, enabling chat search functionalities in applications, and maintaining chat logs for compliance or training purposes.

How to use

To use mcp-server-chat-history, install it via pip or uv, and then run the server. You can also use Docker to run it in a containerized environment.

Key features

Key features include listing recent chats, fetching full chats by chat_id, searching chats by keyword, and appending messages to existing chats.

Where to use

mcp-server-chat-history can be used in applications involving chatbots, customer support systems, and any platform requiring chat history management.

Content

MCP Server Chat History

PyPI - Version
License: MIT
Python

Install with UV in VS Code
Install with UV in VS Code Insiders
Run in Docker

A Model Context Protocol server that provides chat history access and search for agentic LLMs and clients.

Features

  • list_chats: List recent chats for a user
  • get_chat: Fetch full chat by chat_id
  • search_chats: Search a user’s chats by keyword
  • save_message: Append a message to a chat

Quickstart

Install (pip or uv)

pip install mcp-server-chat-history
python -m mcp_server_chat_history

or

uv pip install mcp-server-chat-history
uv run -m mcp_server_chat_history

Docker

docker build -t mcp/chat-history .
docker run -it --rm -p 3000:3000 -v /absolute/path/to/chats:/chats mcp/chat-history

Configuration

Set QODO_CHATLOGS_DIR for your chat logs (default: /chats in Docker, $HOME/all_qodo_chatlogs otherwise):

export QODO_CHATLOGS_DIR=/path/to/your/chatlogs

Usage

After starting the server, connect from your MCP client and call the provided tools.

Available Tools

Tool Params Description
list_chats user_id:str, limit:int=10 List a user’s recent chats
get_chat chat_id:str Fetch full chat data
search_chats user_id:str, query:str Search for a keyword
save_message chat_id:str, role:str, message:str Append a message to a chat

License

MIT

See src/mcp_server_chat_history/main.py for the entrypoint.

Tools

No tools

Comments

Recommend MCP Servers

View All MCP Servers