MemGPT MCP Server
MemGPT MCP 服务器
一个基于 TypeScript 的 MCP 服务器,实现了 LLM 的记忆系统。它提供了与不同 LLM 提供商聊天的工具,同时保留了对话历史记录。
特征
工具
chat- 向当前 LLM 提供商发送消息接受消息参数
支持多个提供商(OpenAI、Anthropic、OpenRouter、Ollama)
get_memory- 检索对话历史记录可选的
limit参数用于指定要检索的记忆数量通行证
limit: null无限制内存检索按时间顺序返回带有时间戳的记忆
clear_memory- 清除对话历史记录删除所有存储的记忆
use_provider- 在不同的 LLM 提供商之间切换支持 OpenAI、Anthropic、OpenRouter 和 Ollama
坚持提供商选择
use_model- 为当前提供程序切换到不同的模型支持特定于提供商的模型:
人择克劳德模型:
克劳德3系列:
claude-3-haiku:响应时间最快,非常适合客户支持和内容审核等任务claude-3-sonnet:均衡的通用性能claude-3-opus:用于复杂推理和高性能任务的高级模型
Claude 3.5系列:
claude-3.5-haiku:提高速度和成本效益claude-3.5-sonnet:具有卓越的计算机交互能力
OpenAI:“gpt-4o”、“gpt-4o-mini”、“gpt-4-turbo”
OpenRouter:任何“提供者/模型”格式的模型(例如,“openai/gpt-4”、“anthropic/claude-2”)
Ollama:任何本地可用的模型(例如“llama2”、“codellama”)
保留模型选择
Related MCP server: MCP Docs RAG Server
发展
安装依赖项:
npm install构建服务器:
npm run build对于使用自动重建的开发:
npm run watch安装
要与 Claude Desktop 一起使用,请添加服务器配置:
在 MacOS 上: ~/Library/Application Support/Claude/claude_desktop_config.json在 Windows 上: %APPDATA%/Claude/claude_desktop_config.json
{
"mcpServers": {
"letta-memgpt": {
"command": "/path/to/memgpt-server/build/index.js",
"env": {
"OPENAI_API_KEY": "your-openai-key",
"ANTHROPIC_API_KEY": "your-anthropic-key",
"OPENROUTER_API_KEY": "your-openrouter-key"
}
}
}
}环境变量
OPENAI_API_KEY- 您的 OpenAI API 密钥ANTHROPIC_API_KEY- 您的 Anthropic API 密钥OPENROUTER_API_KEY- 您的 OpenRouter API 密钥
调试
由于 MCP 服务器通过 stdio 进行通信,调试起来可能比较困难。我们建议使用MCP Inspector :
npm run inspector检查器将提供一个 URL 来访问浏览器中的调试工具。
最近更新
Claude 3 和 3.5 系列支持(2024 年 3 月)
增加了对最新 Claude 模型的支持:
克劳德3系列(俳句、十四行诗、作品)
克劳德3.5系列(俳句、十四行诗)
无限记忆检索
增加了对检索无限对话历史记录的支持
使用
{ "limit": null }和get_memory工具来检索所有存储的记忆使用
{ "limit": n }检索最近的 n 条记忆如果未指定,默认限制为 10
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Related MCP Connectors
past.dev is a long-term memory API for AI agents. Send it timestamped text such as emails, meeting transcripts and support tickets. Ask a question and get the current fact, the value it replaced and the source behind it. With this server, your assistant can recall and save memory and manage your past.dev account.
Memory, reflection and safety for AI agents. Hosted or local, no vector database.
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
An MCP memory server. One memory your agents share — across models, devices and apps.
Related MCP Servers
- AlicenseBqualityDmaintenanceA flexible memory system for AI applications that supports multiple LLM providers and can be used either as an MCP server or as a direct library integration, enabling autonomous memory management without explicit commands.368 npm97MIT
- AlicenseAqualityDmaintenanceA TypeScript MCP server that allows querying documents using LLMs with context from locally stored repositories and text files through a RAG (Retrieval-Augmented Generation) system.417MIT
- FlicenseNot gradedqualityDmaintenanceA TypeScript implementation of the Model Context Protocol server that enables creation, management, and semantic search of memory streams with Mem0 integration.1-
- FlicenseNot gradedqualityDmaintenanceA TypeScript-based MCP server that implements a simple note-taking system using low-level server components and streamable HTTP. It enables users to create, store, and summarize text notes through a set of tools, resources, and specialized prompts.3-