The Memory Layer for AI Agents - Drop-in memory infrastructure for AI agents and apps. Context that persists. Built for production.
Python agentic-memoryagentic-memory-systemagentsaiai-agentschatgptgenaillmlong-term-memorymemorymemory-managementpythonragstate-management
Doc: Mem0 mcp with cursor (#2318)
Dev Khant41a42da774a1
diff --git a/docs/docs.json b/docs/docs.jsonindex 2b14c6190..b8f2db40a 100644--- a/docs/docs.json+++ b/docs/docs.json@@ -200,7 +200,8 @@"integrations/langgraph","integrations/llama-index","integrations/langchain-tools",- "integrations/dify"+ "integrations/dify",+ "integrations/mcp-server"]}]diff --git a/docs/integrations/mcp-server.mdx b/docs/integrations/mcp-server.mdxnew file mode 100644index 000000000..d4bfbef72--- /dev/null+++ b/docs/integrations/mcp-server.mdx@@ -0,0 +1,60 @@+---+title: MCP Server+---++## Integrating mem0 as an MCP Server in Cursor+[mem0](https://github.com/mem0ai/mem0-mcp) is a powerful tool designed to enhance AI-driven workflows, particularly in code generation and contextual memory. In this guide, we'll walk through integrating mem0 as an **MCP (Model Context Protocol) server** within [Cursor](https://cursor.sh/), an AI-powered coding editor.++## Prerequisites+Before proceeding, ensure you have the following installed:+- Cursor IDE+- Python (>=3.8)+- Git+- [mem0-mcp](https://github.com/mem0ai/mem0-mcp) (Clone the repository and set up as per the instructions in the README)+++## Configuring Cursor to use mem0 as an MCP Server++1. **Open Cursor.**+2. **Navigate to `Settings` > `Cursor Settings` > `Features` > `MCP Servers`.**+3. **Add a new provider using the MCP server:**+ - Click on **`Add new MCP server`**+ - Provide a name for the server, e.g. `mem0` and select type as `sse`+ - Enter the **SSE Endpoint**: `http://0.0.0.0:8080/sse`+4. **Save and Restart Cursor** to apply changes.++## Demo+<iframe width="560" height="315" src="https://www.youtube.com/embed/fWa6KX7cpG8?si=cmJDz2sQevGnItSI" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>++## Using mem0 in Cursor+Once integrated, mem0 can assist with contextual memory and AI-driven coding enhancements. Some key functionalities include:++### 1. Storing Coding Preferences+Mem0 can store and manage coding preferences, including:+- Complete code snippets with dependencies+- Language/framework versions+- Documentation and comments+- Best practices and example usage++### 2. Retrieving Stored Preferences+Access all stored coding references to:+- Review implementations+- Maintain consistency in coding practices++### 3. Semantic Search for Preferences+Use natural language queries to find:+- Code snippets+- Technical documentation+- Best practices+- Setup guides++## Benefits of Using mem0 in Cursor+- **Persistent Context Storage**: Retain and reuse coding insights across sessions.+- **Seamless Integration**: Works directly within Cursor as an MCP server.+- **Efficient Search**: Retrieve relevant coding insights using semantic search.++## Conclusion+By integrating mem0 as an MCP server within Cursor, you enhance your development workflow with AI-powered memory and context-aware assistance. Follow the steps above to set up and start leveraging mem0 in your coding environment.++For more details on MCP integration, refer to Cursor's [Model Context Protocol documentation](https://docs.cursor.com/context/model-context-protocol).+diff --git a/docs/integrations/overview.mdx b/docs/integrations/overview.mdxindex 5c2bb69d6..44ef4f052 100644--- a/docs/integrations/overview.mdx+++ b/docs/integrations/overview.mdx@@ -198,4 +198,26 @@ Here are the available integrations for Mem0:>Build AI applications with persistent memory using Dify and Mem0.</Card>+ <Card+ title="MCP Server"+ icon={+ <svg+ viewBox="0 0 180 180"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ >+ <path+ d="M45 45 L135 45 M45 90 L135 90 M45 135 L135 135"+ stroke="currentColor"+ strokeWidth="12"+ strokeLinecap="round"+ fill="none"+ />+ </svg>+ }+ href="/integrations/mcp-server"+ >+ Integrate Mem0 as an MCP Server in Cursor.+ </Card></CardGroup>