rohitg00/agentmemory

#1 Persistent memory for AI coding agents based on real-world benchmarks

What it solves

Coding agents often suffer from "memory loss" between sessions, forcing users to repeatedly explain architectures, preferences, and bug fixes. While some agents use static files like .cursorrules, these are limited in size and quickly become outdated. agentmemory provides a persistent, cross-agent memory layer that captures and compresses session data so agents can recall specific details without manual re-explanation.

How it works

Built on the iii engine, the project runs a memory server that integrates with AI coding agents via hooks, the Model Context Protocol (MCP), or REST APIs. It silently captures agent activity, compresses it into searchable memory, and injects relevant context into new sessions. It supports hybrid search (BM25 and vector embeddings) to retrieve information, with an option for local on-device semantic recall using Xenova/all-MiniLM-L6-v2.

Who it’s for

Developers using AI coding assistants such as Claude Code, Cursor, GitHub Copilot CLI, Gemini CLI, and other MCP-compatible clients who want their agents to maintain a long-term memory of their project and preferences across different tools.

Highlights

  • Cross-Agent Compatibility: Works with a wide array of agents (Claude Code, Cursor, Devin, Aider, etc.) through a single shared memory server.
  • Hybrid Retrieval: Combines keyword search (BM25) and semantic vector search for high recall accuracy.
  • Zero External DBs: Operates without requiring external database installations.
  • Local Embedding Support: Offers free, on-device semantic recall to keep data private and local.
  • High Efficiency: Claims significant token savings by injecting only the necessary context rather than full session histories.

Related

  • Project
  • Project
  • Project
  • Project
  • Project