agents-memory
Ingests OpenAI/ChatGPT session logs and extracts durable rules, facts, and architecture decisions into the local memory store.
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.
Quickstart
pip install agents-memory && agents-memory sync --initScaffolds ~/.agents/memory/, autowires MCP into installed IDEs, and registers assistant skills.
π€ Agent-Driven Setup: Give your coding agent this repo (clone or URL), then tell it to "install and set up agents-memory."
Source checkouts can also be installed and managed with vand.
Related MCP server: agent-julia
What it does
Vendors keep chat in product graves (Cursor jsonl, Claude sessions, Antigravity brains, Open AI exports). agents-memory is the portable layer on top: identity, project map, typed facts. Markdown on disk is the source of truth. MCP is a clerk, not a second store. The search index is disposable FTS5 β delete it, rebuild, same results.
Layer | Where | What lives there |
Global |
|
|
Per repo |
| facts, ADRs, in-progress work (gitignored) |
Always-on | host | short inject; agents |
Search. search_memory tries exact substring first, then FTS5 fill. get_related follows explicit frontmatter relations (refs, supersedes, same_as), not cosine similarity. Known project slug β get_project_memories.
Ingest β staging β distill. Catalog writes titles and paths to chats-index.md. Extract filters user lines into staging/ (PII, how-tos, dumps dropped). You (or distill_batch / memory-distill) promote durable facts into typed files. Chat bodies never become memory. Conversation logs belong to agents-traces.
IDE injection. One sync splices always-on context into hosts it knows (AGENTS.md / rules) and merges MCP where a config file already lives. Text outside <!-- agents-memory-sync --> stays. Details: Where it runs.
Multi-device sync. Unified across all stack domains via agents-sync.
Where it runs
Floor: anywhere with a terminal or an MCP client. Markdown vault + python -m agents_memory mcp is enough. No IDE lock-in.
Deeper support is layered β sync --init autowires what it finds on disk; ingest only covers graves we actually parse.
Layer | What you get | Who |
Vault + MCP/CLI | Full tools ( | Any MCP host / any shell |
Autowire on sync | Merge | Cursor, Claude Code, Claude Desktop, Zed ( |
Always-on / rules | Marked inject block + bound rules |
|
Chat ingest |
| Cursor, Claude Code, Antigravity, VS Code Copilot, Windsurf, Roo, Cline, Pi, Open AI GDPR export |
Ingest β βsupports the product.β Titles/paths + filtered user bullets only β same contract for every source (abi/INGEST.md). Distill is still agent/human judgment.
MCP without autowire: Aider, Continue, Goose, stock Copilot Chat, β¦ β point the host at our stdio server yourself. Vault works; we just do not invent their config path.
Not ingested yet: live Codex rollouts, ChatGPT desktop LevelDB, vendor /memory clouds. Add a source when a parser exists β do not wholesale-import foreign memory.
Cloud sync (agents-sync)
Cloud and multi-device synchronization for ~/.agents/memory/ (and the entire ~/.agents stack: skills, docs, rules, traces, identity) has been decoupled into the dedicated package: agents-sync.
agents-sync coordinates state across local workstations, laptops, and remote VPS agent servers:
pip install agents-sync
# Connect this node to your cloud vault
agents-sync connect https://vps.example.com:8765 --token YOUR_TOKEN
# 2-way sync across all stack domains (memory, skills, docs, rules, traces, identity)
agents-sync syncMCP tools
Primary surface. Agents talk to the vault here β not via scraping CLI help.
Tool | What it does |
| Exact substring, then FTS5 fill. Not chat graves. Known slug β |
| Follow frontmatter |
| File a typed fact; auto-syncs inject |
| Raw file by id ( |
| One slugβs in-tree memory (call when opening a repo) |
| Project map |
| Staging β typed memory |
| Drop a search hit by id |
| Rewrite always-on inject |
| Propose a hard rule into staging (the user applies it) |
Sixteen tools. Full contract: abi/MCP.md. Session snap/grep/tail live on agents-traces.
Hard rules
Always-on rules live in ~/.agents/memory/rules/HARD.md, one imperative rule per line. A project can add projects/<slug>/RULES.md. One renderer builds a <memory_rules> block for the MCP instructions, the first tool result of each session (plus a project's rules on its first project-scoped call), agents-memory context, and the synced AGENTS.md / agent rule. Budget: 30 lines and 2000 characters globally, 10 lines per project (AGENTS_MEMORY_RULES_MAX_LINES, AGENTS_MEMORY_RULES_MAX_CHARS, AGENTS_MEMORY_RULES_PROJECT_MAX_LINES). Agents only propose_rule into staging/rule-proposals.md; the user edits with agents-memory rules.
CLI
Ops / install / batch. Humans and agents rarely need the vault CRUD verbs β those mirror MCP for scripts. Machine-readable catalog: python -m agents_memory --help-json (do not scrape --help).
Command | Purpose |
| Always-on inject, first-run scaffold, optional mirror push |
| Disk vs |
| MCP vault mirrors (scripts / no-MCP hosts) |
| Chat catalog and staging extract |
| Staging inbox / noise pass |
| Rendered hard rules |
| Edit hard rules (budgeted) |
| Mechanical store health (no LLM) |
| Rebuild disposable FTS5 cache (MCP start already rebuilds) |
| Local viewer / static HTML export |
| Clear local caches / temp state |
| stdio MCP clerk |
extract-openai is deprecated β ingest extract (openai-export source).
ABI
Implementation-agnostic layout in abi/:
WHY.mdβ why markdown wins over RAG-as-memoryLAYOUT.mdβ directory contractKINDS.mdβ typed taxonomyHYGIENE.mdβ lifetimes, write boundariesMCP.mdβ tool surfaceINGEST.mdβ catalog β extract β distillINJECTION.mdβ host inject
Tests
python tests/run_all_tests.pyLicense
MIT. See LICENSE.
This server cannot be deployed
Maintenance
Related MCP Connectors
One memory, every AI. A shared, user-owned markdown memory your AI clients read and write over MCP.
Persistent AI memory shared across Claude, ChatGPT, coding agents, and compatible MCP clients.
- ContexelOAuthai.contexel
Shared AI memory. ChatGPT, Claude, Cursor and any MCP app read and write the same memory.
Persistent memory for AI agents across Claude, ChatGPT and any MCP client.
Related MCP Servers
- AlicenseAqualityCmaintenancePersistent memory MCP server for Claude Code, Cursor, and GitHub Copilot. Semantic search, Git sync, project-based, Persistent memory MCP server for Claude Code, Cursor, and GitHub Copilot. Semantic search, Git sync, project-based organization, and team collaboration via Model Context Protocol.11216 npm2MIT
- AlicenseNot gradedqualityAmaintenanceLocal-first MCP server providing persistent markdown memory with persona engine and fast search, designed to unify AI assistant memory across Claude Code, Cowork, and Dispatch.25 npm1MIT
- AlicenseNot gradedqualityCmaintenanceA local-first, team-ready MCP server providing durable memory for LLM-based coding workflows with multiple storage backends and fast search.4MIT
- AlicenseBqualityDmaintenanceLocal-first memory server for AI coding agents that stores work sessions, tasks, and durable memories in Markdown files, exposed through MCP tools for session management and memory retrieval.104 npm1MIT