memory-bridge
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
English | العربية | 简体中文 | Español
🧠 Local AI Memory Bridge
Persistent, encrypted, fully offline long-term memory for AI agents (Claude Code, Cursor, and any MCP client). Your memories never leave your machine.
⚠️ Status: alpha (v0.1). Save, search, redaction and the MCP server are tested from the CLI and a test MCP client. Not yet tested with every agent.
compacthas had limited testing. Do not rely on it for highly sensitive data yet.
Why
🔒 Whole-database encryption (SQLCipher) plus AES-256-GCM on every memory text
🔑 Master key in your OS keychain (falls back to a
chmod 600key file where no keychain exists, e.g. Codespaces or Docker)🧹 Secrets redacted before anything is embedded or stored (API keys, tokens, passwords, JWTs, private keys, credit cards, emails)
🌍 Multilingual semantic search (
multilingual-e5-small, 100+ languages including Arabic), running locally via ONNX🔌 Native MCP server over stdio
Related MCP server: aci-mcp
Architecture
flowchart LR
A[AI Agent<br/>Claude Code / Cursor] -- MCP stdio --> B[MCP Server]
B --> C[PII Redaction<br/>regex + entropy]
C --> D[Local Embeddings<br/>e5-small ONNX]
D --> E[(SQLCipher DB<br/>sqlite-vec + AES-GCM text)]
K[OS Keychain] -. master key .-> E
E --> F[Compaction<br/>cluster + dedupe]Quick Start
Requires Node.js 20 or newer.
npx -y local-ai-memory-bridge add "I prefer TypeScript for new projects"
npx -y local-ai-memory-bridge search "what language do I prefer?"
npx -y local-ai-memory-bridge setupThe first add or search downloads the embedding model (about 100-150 MB) to ~/.memory-bridge/models. Run one of them once before connecting an agent, so the agent does not time out on the first call.
Connect to Claude Code
claude mcp add memory-bridge -- npx -y local-ai-memory-bridge serve
claude mcp listConnect to Cursor (mcp.json)
{
"mcpServers": {
"memory-bridge": {
"command": "npx",
"args": ["-y", "local-ai-memory-bridge", "serve"]
}
}
}CLI
Command | Description |
| Run the MCP server (stdio) |
| Save a memory (redacted automatically) |
| Semantic search |
| Delete a memory |
| Merge near-duplicate memories older than N days |
| Show counts and DB path |
| Print MCP config snippets |
MCP Tools
Tool | Input | Purpose |
|
| Store a durable fact or decision |
|
| Semantic recall |
|
| Delete a memory |
Configuration
Env var | Default | Meaning |
|
| Data directory |
| (unset) | 64-char hex master key override |
|
| Embedding model |
|
| Relevance cut-off relative to the best hit |
Your encryption key (read this)
Your memories can only be opened with the master key.
If the OS keychain entry is deleted, or you move to a new machine without the key, the database cannot be opened and the data is unrecoverable.
You will see:
Cannot decrypt memory.db: the master key does not match.... Either restore your key viaMEMORY_BRIDGE_KEY, or delete~/.memory-bridge/memory.dbto start fresh.To control the key yourself, generate one (
openssl rand -hex 32), store it in a password manager, and set it asMEMORY_BRIDGE_KEY.In ephemeral environments (Codespaces, containers), the key and database may be lost when the environment is deleted.
Security model and limits
Redaction is best-effort (patterns plus entropy). It will miss some secrets, so don't rely on it as your only control.
This protects data at rest on your machine, not against malware running as your user.
This project has not had an independent security review.
Roadmap
One-command install via npm (
npx)Key export / backup command
Optional NER-based PII detection
Optional local-LLM summarization (Ollama)
Tests and CI
License
MIT
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Persistent personal memory for AI assistants — save, search, and recall across every MCP client.
Hosted agent memory: store, search, and recall facts across sessions from any MCP client.
Private-by-default, local-first memory/context/task orchestrator for MCP apps and agents.
Private persistent memory for Claude, ChatGPT & Gemini via MCP - semantic search, zero-code setup.
Related MCP Servers
AlicenseNot gradedqualityDmaintenanceProvides a private, on-device memory with semantic search for MCP clients, enabling encrypted storage and recall of context facts without external API calls.72 npmApache 2.0- AlicenseAqualityCmaintenanceProvides a local-first, provenance-aware memory layer that enables MCP-capable AIs to store, recall, validate, and reason over facts with contradiction detection, trust weighting, deduplication, and encryption, supporting offline private operation without GPUs or API keys.9Apache 2.0
- AlicenseNot gradedqualityCmaintenanceProvides AI agents with persistent local memory management, including semantic recall, knowledge graph traversal, and automatic memory consolidation, enabling structured long-term memory across MCP clients.Apache 2.0
- AlicenseAqualityCmaintenanceProvides persistent local memory for any MCP-compatible AI agent, enabling agents to store, search, recall, forget, export, and manage preferences, rules, and facts with zero dependencies, no cloud, and no API keys.8MIT