agentmemory Review: Persistent Memory for AI Coding Agents
agentmemory, an open-source persistent memory layer for AI coding agents, has become the #1 trending GitHub repo as of May 2026 with 9,361 stars (6,467 this week). It silently captures agent actions, compresses them into searchable memory, and injects relevant context into the next session. The system supports multiple agents including Claude Code, Cursor, Codex CLI, Gemini CLI, Cline, Windsurf, Roo Code, OpenCode, and any MCP-compatible tool. It achieves 95.2% R@5 on LongMemEval-S (ICLR 2025, 500 questions), outperforming mem0 (68.5%) and Letta/MemGPT (83.2%). The approach uses ~170K tokens/year versus ~19.5M for paste-full-context methods, costing roughly $10/year (free with local embeddings). It provides 12 auto-capture hooks for Claude Code, 6 for Codex CLI, and an MCP server for other tools, plus 51 MCP tools including memory_smart_search, memory_save, memory_sessions, and memory_governance_delete. The system is local-first with SQLite and iii-engine, requiring no external dependencies like Qdrant or Postgres. It is MIT licensed and available as the npm package @agentmemory/agentmemory.
Eliminates re-explaining context to AI agents, saving time and reducing token costs by 100x.