evangstav_python-memory-mcp-server
Memory MCP Server is an implementation of the Model Context Protocol (MCP) server designed to manage Claude's memory and knowledge graph.
Memory MCP Server
An implementation of the Model Context Protocol (MCP) server for managing Claude's memory and knowledge graph.
Installation
You can install the package using uv
:
uvx memory-mcp-server
Or install it from the repository:
uv pip install git+https://github.com/estav/python-memory-mcp-server.git
Usage
Once installed, you can run the server using:
uvx memory-mcp-server
Configuration
The server expects certain environment variables to be set:
DATABASE_URL
: SQLite database URL for storing the knowledge graph- Add any other configuration variables here...
Integration with Claude Desktop
To use this MCP server with Claude Desktop, add the following to your claude_desktop_config.json
:
{
"mcpServers": {
"memory": {
"command": "uvx",
"args": ["memory-mcp-server"]
}
}
}
Development
- Clone the repository:
git clone https://github.com/estav/python-memory-mcp-server.git
cd python-memory-mcp-server
- Create a virtual environment and install dependencies:
uv venv
source .venv/bin/activate
uv pip install -e ".[test]" # Include test dependencies
- Run tests:
pytest # Run all tests
pytest -v # Run with verbose output
pytest -v --cov # Run with coverage report
- Run the server locally:
python -m memory_mcp_server
Testing
The project uses pytest for testing. The test suite includes:
Unit Tests
test_knowledge_graph_manager.py
: Tests for basic knowledge graph operationstest_optimized_knowledge_graph_manager.py
: Tests for optimized/batch operationstest_server.py
: Tests for MCP server implementation
Running Tests
# Run all tests
pytest
# Run with coverage report
pytest --cov=memory_mcp_server
# Run specific test file
pytest tests/test_server.py
# Run tests with verbose output
pytest -v
Test Fixtures
The conftest.py
file provides common test fixtures:
temp_db_path
: Creates a temporary SQLite databaseknowledge_graph_manager
: Provides a KnowledgeGraphManager instanceoptimized_knowledge_graph_manager
: Provides an OptimizedKnowledgeGraphManager instance
License
This project is licensed under the MIT License - see the LICENSE file for details.
Related MCP Servers
View all knowledge_and_memory servers →git-mcp
by idosal
GitMCP is a free, open-source, remote Model Context Protocol (MCP) server that transforms GitHub projects into documentation hubs, enabling AI tools to access up-to-date documentation and code.
Knowledge Graph Memory Server
by modelcontextprotocol
A basic implementation of persistent memory using a local knowledge graph, allowing Claude to remember information about the user across chats.
mcpdoc
by langchain-ai
MCP LLMS-TXT Documentation Server provides a structured way to manage and retrieve LLM documentation using the Model Context Protocol.
rust-docs-mcp-server
by Govcraft
The Rust Docs MCP Server provides an up-to-date knowledge source for specific Rust crates, enhancing the accuracy of AI coding assistants by allowing them to query current documentation.
mindmap-mcp-server
by YuChenSSR
A Model Context Protocol (MCP) server for converting Markdown content to interactive mindmaps.
algorand-mcp
by GoPlausible
This is a Model Context Protocol (MCP) implementation for Algorand blockchain interactions, providing a server package for blockchain interactions and a client package for wallet management and transaction signing.
mcp-obsidian
by MarkusPfundstein
MCP server to interact with Obsidian via the Local REST API community plugin.