Sponsored by Deepsite.site

Mem0 General

Created By
ryaker7 months ago
OpenAI just added memory across your chats across your openAI account. But wouldn't it be awesome to have general AI memory across all your interactions with any and all AI tools, IDEs, chatbots.... Now if it supports MCP you can with https://mem0.ai/ Give Claude desktop memory. Give cursor or windsurf memory across sessions or different projects.
Content

Mem0 MCP Server

A Model Context Protocol (MCP) server for integrating AI assistants with Mem0.ai's persistent memory system.

Overview

This server provides MCP-compatible tools that let any compatible AI assistant access and manage persistent memories stored in Mem0. It acts as a bridge between AI models and the Mem0 memory system, enabling assistants to:

  • Store and retrieve memories
  • Search memories with semantic similarity
  • Manage different memory types (episodic, semantic, procedural)
  • Utilize short-term memory for conversation context
  • Apply selective memory patterns
  • Create knowledge graphs from memories

Project Structure

The project has been refactored from a monolithic design to a modular structure:

mem0_mcp_server/
├── core/                   # Core functionality
│   ├── client.py           # Mem0 client initialization 
│   ├── logging.py          # Logging configuration
│   └── server.py           # MCP server setup
├── operations/             # Basic memory operations
│   └── basic.py            # Add, search, get, delete, update
├── memory_types/           # Specialized memory implementations
│   ├── short_term.py       # Conversation, working, attention
│   └── specialized.py      # Episodic, semantic, procedural
└── advanced/               # Advanced features
    ├── features.py         # Categories, instructions, graph, feedback
    └── selective.py        # Pattern-based memory filtering

app.py                      # Main entry point

Getting Started

Setting up in Cursor or Claude Desktop

  1. Install the package:
pip install mcp-mem0-server
  1. Add the following configuration to your MCP configuration file:

For Cursor, add this to ~/.cursor/mcp.json:

"mem0-memory-general": {
  "command": "mcp-mem0-server",
  "args": [],
  "env": {
    "MEM0_API_KEY": "your-mem0-api-key-here"
  }
}

For Claude Desktop, add a similar configuration in your settings.

  1. Restart Cursor or Claude Desktop to apply the changes.

Memory Types

The server supports different memory types organized by duration and function:

Short-Term Memories

  • Conversation Memory: Recall of recent message exchanges
  • Working Memory: Temporary information being actively used
  • Attention Memory: Information currently in focus

Long-Term Memories

  • Episodic Memory: Specific events and experiences
  • Semantic Memory: Facts, concepts, and knowledge
  • Procedural Memory: Skills and how-to information

Advanced Features

  • Custom Categories: Define and manage your own memory categories
  • Memory Instructions: Set guidelines for how memories should be processed
  • Graph Relations: Access knowledge graph relationships between entities
  • Selective Memory: Filter text with include/exclude patterns before storing
  • Feedback Mechanism: Provide feedback on memory quality

Usage

All memories in the system use "default_user" as the default user_id.

For detailed usage examples, see the USAGE_GUIDE.md.

Documentation

License

This project is licensed under the MIT License - see the LICENSE file for details.

Acknowledgments

  • Mem0.ai for their excellent memory API
  • FastMCP for the MCP server implementation
  • All contributors to this project

Server Config

{
  "mcpServers": {
    "mem0-memory-general": {
      "command": "<PATH TO SERVER>/mcp-mem0-server",
      "args": [],
      "env": {
        "MEM0_API_KEY": "<YOUR MEM0 KEY>"
      }
    }
  }
}
Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
Amap Maps高德地图官方 MCP Server
Context7Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
Serper MCP ServerA Serper MCP Server
Playwright McpPlaywright MCP server
WindsurfThe new purpose-built IDE to harness magic
ChatWiseThe second fastest AI chatbot™
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
CursorThe AI Code Editor
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
Tavily Mcp
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
DeepChatYour AI Partner on Desktop
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs