Skip to main content
Glama

agents-memory

Local markdown memory & cross-agent context engine for AI coding assistants.
One persistent identity, shared across Claude Code, Cursor, Antigravity, and Zed.


Quickstart

1-Step Setup

pip install agents-memory && agents-memory sync --init

Scaffolds ~/.agents/memory/, autowires MCP configurations into your installed IDEs, and registers assistant skills.

TIP

๐Ÿค– Agent-Driven Setup (Zero Friction):
Simply tell your coding agent: "Install and set up agents-memory for me."
The agent installs the package, asks your stack preferences once, fills your USER.md profile, and registers your repositories autonomously.

Source checkouts can also be installed and managed using vand.


Related MCP server: Jarvis Markdown MCP

Why .agents/memory?

The name agents-memory comes directly from its universal storage standard: .agents/memory.

  • Global: ~/.agents/memory/ stores your persistent identity, stack defaults, durable concepts, and project index.

  • Repository: <repo>/.agents/memory/ stores repo-specific facts, architecture ADRs, and staging inboxes.

While AI vendors fragment their configuration across proprietary stores, .agents/ provides a single, open, vendor-neutral filesystem hub for all agent configurations and shared intelligence.

agents-memory delivers this with a pure Markdown-first architecture:

  • Local & Offline: Your identity and repo memory live in plain files (~/.agents/memory/ and <repo>/.agents/memory/).

  • Human-Readable & Git-Friendly: Edit with any text editor, diff with git, commit when you want.

  • Universal MCP Server: Exposes memory tools (search_memory, add_memory, get_project_memories, distill_batch, get_baton, set_baton, append_chronicle, session_snap, session_grep, search_hybrid, get_related, suggest_links, check_memory_freshness) to all modern agents.

  • Ranked Hybrid Retrieval: Exact-substring precision first with SQLite FTS5 fallback and bidirectional wikilink relation navigation.

  • Autonomous Ingest & Distillation: Extracts durable rules and architecture decisions from session logs (OpenAI, Claude, Cursor, Copilot, Antigravity, Pi).


Architecture & Flow

 โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
 โ”‚                       SESSION INGEST                        โ”‚
 โ”‚  OpenAI Exports ยท Claude JSONL ยท Cursor ยท Antigravity ยท Pi  โ”‚
 โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                                โ”‚  ingest catalog / extract
                                โ–ผ
 โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
 โ”‚                       STAGING INBOX                         โ”‚
 โ”‚        Raw captured bullets & noise-filtered facts          โ”‚
 โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                                โ”‚  distill_batch / skill
                                โ–ผ
 โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
 โ”‚                     LOCAL MEMORY STORE                      โ”‚
 โ”‚   ~/.agents/memory/USER.md     ~/.agents/memory/PROJECTS.md โ”‚
 โ”‚   ~/.agents/memory/concepts/   <repo>/.agents/memory/       โ”‚
 โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                โ”‚                               โ”‚
                โ–ผ                               โ–ผ
 โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
 โ”‚       IDE INJECTION         โ”‚ โ”‚     MCP SERVER & CLERK      โ”‚
 โ”‚  Cursor Rules ยท Zed Context โ”‚ โ”‚  search_memory ยท add_memory โ”‚
 โ”‚  Antigravity AGENTS.md      โ”‚ โ”‚  Universal Tool Integration โ”‚
 โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

CLI Reference

Command

Purpose

agents-memory sync

Updates canonical AGENTS.md, host rules, and MCP registrations

agents-memory sync --init

First-time scaffolding, example creation, and host discovery

agents-memory inventory

Discovers unregistered local repositories across workspace roots

agents-memory inventory --register SLUG PATH ROLE STACK

Registers a new repository

agents-memory ingest catalog

Indexes local chat transcripts across all supported providers

agents-memory ingest extract

Runs heuristic filters to extract durable facts into staging

agents-memory distill

Inspects staging inbox for distillation

agents-memory check

Zero-AI mechanical store health checks (stubs, duplicates, leaks)

agents-memory rebuild-index

Rebuilds the disposable local SQLite FTS5 search index

agents-memory serve

Starts local interactive memory browser on localhost:8765

agents-memory web

Exports static HTML documentation site for your memory store

agents-memory consolidate

Ensures no private state leaked into working repository


MCP Tools Reference

Tool

Parameters

Description

search_memory

query, project, limit

Exact-substring precision first with ranked SQLite FTS5 fallback.

add_memory

fact, kind, name, project

Proactively save durable facts, concepts, ADRs, or rules directly to memory.

get_project_memories

project, cwd

Retrieve project-specific facts, architecture decisions, and active work files.

get_staging_inbox

None

Retrieve unreviewed captured bullets across user and project staging files.

distill_batch

items_json

Batch promote durable facts to permanent files or discard throwaway noise.

promote_bullet

bullet, kind, name, project

Promote a single staging bullet to permanent memory.

get_baton

project, cwd

Read the active session baton handover note for context continuity.

set_baton

text, project, cwd

Update the session baton handover note for the next agent session.

append_chronicle

beat, project, emoji, refs

Record a major milestone or beat in the project's temporal chronicle.

session_snap

limit, project, cwd

Snapshot recent user query history and active session baton.

session_grep

pattern, since, project

Fast regex search across indexed session transcripts.

session_tail

session_id, limit

Tail recent user interaction lines from session logs.

search_hybrid

query, limit

Hybrid search combining SQLite FTS5 text rank with wikilink relations.

get_related

file_path, depth

Traverse explicit wikilink relations, references, and backlinks.

check_memory_freshness

None

Mechanical audit of staging backlog and stale project batons.


Supported Ecosystem

  • Claude Code: Bound via symlink / canonical AGENTS.md and MCP server.

  • Google Antigravity: Integrated via .gemini/config rules and agents-memory MCP.

  • Cursor: Automatically injects rules and configures .cursor/mcp.json.

  • Zed: Configures context_servers and mirrors assistant skills.

  • VS Code / Copilot: Ingests session history from local state databases.

Also compatible with: Windsurf, Cline, Roo-Code, Aider, Continue.dev, OpenAI ChatGPT, Pi, Goose, and any MCP-compliant AI assistant.


Open ABI Specification

The formal, implementation-agnostic layout specification lives in abi/:

  • abi/WHY.md โ€” Architecture decisions & why Markdown wins over RAG.

  • abi/LAYOUT.md โ€” Directory taxonomy and path contracts.

  • abi/KINDS.md โ€” Typed memory taxonomy (concepts, facts, decisions).

  • abi/HYGIENE.md โ€” Store hygiene doctrine, anti-bloat rules, and health checks.

  • abi/MCP.md โ€” Tool surface definitions and request/response specifications.

  • abi/INGEST.md โ€” Catalog, extract, and distillation pipeline.

  • abi/INJECTION.md โ€” Host rule injection mechanisms.


Testing & Verification

Run the comprehensive test suite and distillation benchmark:

python tests/run_all_tests.py

License

MIT License. See LICENSE for details.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

No tool schema history has been recorded yet.

Maintenance

ActivityMaintained
ResponsivenessSyncing

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    A
    maintenance
    Local-first, file-based memory layer for AI agents โ€” one shared Markdown vault across Claude, Codex, Gemini, Cursor and any MCP client. Provides read/write memory tools with an audit trail, per-agent trust levels, and Git sync; no cloud and no lock-in.
    2
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Provides portable memory for AI agents using plain Markdown files. Enables storing, recalling, and managing memories via MCP tools like recall, remember, forget, list, and get.
    5
    1
    MIT
  • A
    license
    Not graded
    quality
    B
    maintenance
    Provides a file-first personal memory layer for AI agents, enabling them to store and retrieve memories as markdown files with an SQLite index. The MCP server offers read-only search by default, with optional write tools for manual memory addition and conflict resolution.
    11
    MIT

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Lolaplex/agent-memory'

If you have feedback or need assistance with the MCP directory API, please join our Discord server