memory-mcp
Verified Safeby Calvin-Francis
Overview
Provides AI assistants with persistent semantic memory and knowledge graph capabilities, enabling cross-session memory, semantic retrieval, and complex reasoning.
Installation
npm startEnvironment Variables
- DATABASE_URL
- DASHSCOPE_API_KEY
Security Notes
The server uses parameterized SQL queries throughout `memory.js` and `graph.js` to prevent SQL injection. Configuration, including API keys and database connection strings, is loaded from environment variables, avoiding hardcoded secrets. Communication occurs over standard I/O (stdio) via JSON-RPC 2.0, which significantly limits external network attack surface. An LRU cache is implemented for embedding generation, reducing frequent calls to external APIs. While the server directly parses arbitrary JSON from stdin, there is no explicit input schema validation before arguments are passed to service functions. PostgreSQL's strong typing does offer a layer of protection against unexpected data types being directly inserted. There is a theoretical potential for denial-of-service (DoS) if excessively large or deeply nested JSON inputs are provided via stdin, though this is less critical for a local stdio connection.
Similar Servers
nocturne_memory
Provides a persistent, structured long-term memory and dynamic knowledge graph system for AI agents, designed for human-AI collaboration.
post-cortex
Provides long-term, persistent memory and knowledge management for AI assistants, enabling them to store, semantically search, and retrieve conversation context, decisions, and code-related insights.
amp
Provides a persistent, structured memory (Short-Term, Long-Term, and Graph) for AI agents, mimicking a hippocampus for continuous learning and recall.
remind
Generalization-capable memory layer for LLMs that extracts, stores, and retrieves semantic concepts from raw episodic experiences, mimicking human memory consolidation.