DNA Memory MCP

Local memory for Claude Code, Codex and Claude Desktop: one Markdown folder and one MCP server shared by all.

  • 103 ★ on the repository
  • Last commit
  • Apache-2.0
MCP server

Extended access

Why this level

  • The server reads and writes files in the memory folder and keeps conclusions about your projects there.
All reasons and checks

aipmandy/dna-memory

Install

Manual install

git clone https://github.com/AIPMAndy/dna-memory.git "$HOME/.local/share/dna-memory/app"

Then a virtual environment with requirements-mcp.txt, a DNA_MEMORY_PROFILE profile and wiring into a client with claude mcp add.

Access and checks

How we review

Extended accessThe tool runs code or makes network calls and only reads external data.

  • The server reads and writes files in the memory folder and keeps conclusions about your projects there.

This is third-party code. Review the repository files before installing.

What it does

DNA Memory keeps agents' long-term memory in a Markdown or Obsidian folder and uses SQLite as a deletable, rebuildable index. Codex, Claude Code, Claude Desktop and Hermes talk to one MCP server, so each tool no longer keeps its own copy of memory. Full conversations stay with the clients: the server stores only bounded source pointers, reviewed proposals and verified conclusions. The `memory_remember`, `memory_recall` and `memory_feedback` tools store a conclusion, find it by keyword before a new task and take a `useful` or `misleading` mark. Content falls into eight types including preferences, facts, decisions, project state, open loops and workflows. Duplicates are dropped and stale entries are replaced through an explicit `supersedes`. A filter discards transient state and credentials.

Who it is for. People who work in several agents at once, Codex, Claude Code, Claude Desktop or Hermes, and are tired of mismatched memories.

Good fit when

  • A decision made in Claude Code should be known to Codex the next day.
  • Memory lives in Obsidian notes and has to be readable and editable by hand.
  • Before a new task the agent should recall preferences and mistakes from past sessions.
  • You want to retire an outdated conclusion and replace it with a new one through an explicit link.

Not a fit when

  • You need an archive of every conversation: the server keeps conclusions while full sessions stay with clients.
  • Your client cannot launch a local program: the server works over stdio.
  • You need cloud sync without your own folder and Git.

Example request

Recall which architecture decisions we made earlier for this project and store a new conclusion about dropping the cache with its source.

MCP

Transport
stdio
Authentication
not required

Environment variables

DNA_MEMORY_PROFILE required
Path to the profile file with the knowledge folder and the memory subfolder.

Limitations

Python 3.9 or newer is required, and the MCP server needs its own virtual environment with dependencies from `requirements-mcp.txt`. The settings path is set with the `DNA_MEMORY_PROFILE` variable, and the profile names the knowledge folder and the subfolder DNA Memory manages. Do not hand it a whole Obsidian vault. Installation is a `git clone` plus manual wiring into each client: the commands differ for Claude Code, Codex and Hermes, and Claude Desktop has a separate guide. Stored memory does not count as verified until a write, a recall in one client, a recall in another and feedback all succeed.

How to disable. Remove the server with `claude mcp remove dna-memory`. Notes live in your folder and stay; the SQLite index can be deleted and rebuilt with `python3 dna.py memory reindex --json`.

FAQ

How do I connect DNA Memory to Claude Code?

Run `claude mcp add --scope user dna-memory -e "DNA_MEMORY_PROFILE=$PROFILE" -- "$PYTHON" "$ROOT/scripts/memory_mcp.py"`, then `claude mcp get dna-memory`.

How do I check that memory works?

Store a test conclusion with `memory_remember`, find it with `memory_recall`, send `memory_feedback` and find the same conclusion in another client.

What is stored?

Preferences, facts, decisions, project state, open loops and workflows, eight types in all. Full conversations and transient states are not kept.

How do I replace an outdated conclusion?

Create a new one with a `supersedes` field pointing to the old one. Or delete the file in the memory folder and run `memory reindex`.

Is Obsidian required?

No, any Markdown folder works. Obsidian is a convenient editor but the server works without it.

Discussion

No questions or reviews yet.

Long-term agent memory in local Markdown files with a link graph, semantic search and MCP access

MCP serverExtended access4.6KRepository stars

Local memory for agents with a review queue: SQLite, an audit log and a token ledger, one vault for Claude Code, Codex and Cursor

PluginExtended access180Repository stars

Persistent memory for coding agents: insights are stored as markdown cards and recalled at the start of the next session.

MCP serverExtended access144Repository stars

A local workbench for Claude Code, Codex, Pi and OpenCode: memory changes wait for your review, then an audit follows each turn

CLIExtended access279Repository stars

Agent memory as a graph of linked facts: decisions and errors outlive the session, with no vector database or paid API calls

MCP serverExtended access244Repository stars

One local memory shared by Claude Code, Codex and OpenClaw: tell one agent, another knows tomorrow, no cloud or keys.

PluginExtended access111Repository stars

README in short

Documentation in Chinese and English explains processing memory before storing it, the steps from signal to verified conclusion and a quick setup. Separate files describe client adapters and skill management.

README badge

Report a problem