Local-first shared project memory for AI coding agents: one SQLite-backed store, scoped to the Git repository, that Claude Code, Codex, Cursor, Copilot, Gemini CLI and other MCP clients all read and write.
EngramMCP Server
Summary
Persistent memory for coding agents as a single Go binary — SQLite and FTS5 behind MCP, an HTTP API, a CLI and a TUI, with no Node, Python or Docker required.
Features
- Single Go binary with SQLite + FTS5 — no Node.js, Python or Docker dependency
- Reachable over MCP stdio, an HTTP API, a CLI and an interactive TUI
- Stable topic keys so an evolving subject updates one memory instead of forking
- Session summaries that double as the recovery path after context compaction
- mem_review, mem_judge and mem_compare for auditing stale or conflicting knowledge
- Git Sync exports portable compressed chunks; Engram Cloud replication is optional
- engram setup writes config for 12+ agents including Claude Code, Codex, Cursor and Gemini CLI
Installation
Set up this MCP server in your favorite AI agent — copy a ready-made configuration below.
Description
A coding agent forgets everything when the session ends. Engram is a memory store built to survive that boundary, and it is deliberately unglamorous about how: one Go binary, one SQLite file at ~/.engram/engram.db, full-text search through FTS5. No Node.js, no Python, no Docker, no server to keep running for the usual stdio setup.
A curated memory, not a transcript sink
The distinctive part is the operating contract the project asks agents to follow, which is what separates a useful memory from a log nobody can search. Orient first (mem_current_project, mem_context) to recover relevant history. Search before repeating a decision or bug you may already have solved. Retrieve progressively — mem_search for candidates, mem_timeline when surrounding context matters, mem_get_observation before relying on a full record. Save deliberately: completed fixes, decisions, discoveries, configuration changes and durable user constraints, never raw tool output or every conversational turn.
Evolving topics get a stable topic_key such as architecture/auth-model, so revisiting a subject updates one memory instead of accumulating competing ones — with mem_suggest_topic_key to pick a key when it is unclear. Sessions close with a mem_session_summary handoff, which doubles as the recovery path after context compaction.
Four interfaces, one store
MCP over stdio is the agent-facing path, and the same database is reachable through an HTTP API, a CLI and an interactive TUI — useful for reviewing what an agent has actually been remembering. mem_review, mem_judge and mem_compare exist for auditing stale knowledge and relationships between memories.
Local first, portable when needed
The local SQLite database is authoritative. Git Sync exports portable compressed chunks for moving memory between machines; Engram Cloud is an optional, project-scoped replication layer with browser visibility and shared access. Project-aware reads resolve to a canonical current project (explicit flag, then ENGRAM_PROJECT, then cwd detection), with --all reserved for an intentional global read.
engram setup <agent> writes the configuration for Claude Code, Pi, OpenCode, Gemini CLI, Codex, Antigravity CLI, Windsurf, Qwen Code, Kiro, Cursor, VS Code Copilot and Kilo Code. MIT licensed; installable via Homebrew.
Related MCP Servers
See all Engram alternativesMCP: OKF Agent Memory
by okf-memory
Git-native persistent memory for coding agents — sub-300µs BM25 search over version-controlled plain text, with no embeddings, no database and no API costs.
MCP: Memory
by Model Context Protocol
A knowledge-graph-based persistent memory system that lets an agent remember entities and relations across sessions.
Self-hosted, open-source persistent memory for AI agents over MCP and REST: semantic plus keyword search with local ONNX embeddings, a shared knowledge graph, consolidation, and SQLite, Cloudflare or Milvus backends.