Doc: Mem0 mcp with cursor (#2318)
This commit is contained in:
@@ -200,7 +200,8 @@
|
|||||||
"integrations/langgraph",
|
"integrations/langgraph",
|
||||||
"integrations/llama-index",
|
"integrations/llama-index",
|
||||||
"integrations/langchain-tools",
|
"integrations/langchain-tools",
|
||||||
"integrations/dify"
|
"integrations/dify",
|
||||||
|
"integrations/mcp-server"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
60
docs/integrations/mcp-server.mdx
Normal file
60
docs/integrations/mcp-server.mdx
Normal file
@@ -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).
|
||||||
|
|
||||||
@@ -198,4 +198,26 @@ Here are the available integrations for Mem0:
|
|||||||
>
|
>
|
||||||
Build AI applications with persistent memory using Dify and Mem0.
|
Build AI applications with persistent memory using Dify and Mem0.
|
||||||
</Card>
|
</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>
|
</CardGroup>
|
||||||
|
|||||||
Reference in New Issue
Block a user