git-native memory for AI agents

Give your AI agents
a git repo as a brain

Agents forget everything between sessions. mnemo gives them a persistent, versioned, auditable memory that lives inside your project — stored as plain files, committed with git, and recalled on demand.

npm mnemo-mem CI passing MIT license zero dependencies

the problem

Every agent starts from zero.
Every single session.

You ask your coding agent to pick a database. It does. Then you close the session — and next time it picks something different, because it never remembered.

Context evaporates

New session, blank brain. Every decision you paid tokens to make is gone the moment you close the terminal.

Re-explaining forever

“Remember, we already decided on postgres.” You type that sentence dozens of times — wasting tokens and patience.

No audit trail

When your agent “knew” something and when — good luck. There’s no git history for the things that mattered.

the fix

Memory that behaves like code

mnemo treats an agent’s memory the way git treats source: versioned, diffable, branchable, and inspectable at any point in time.

Auto-capture

At the end of every OpenCode session the plugin summarizes what happened and stores it — automatically.

Relevance search

Ranked BM25 retrieval returns only the top memories that matter — so the agent gets signal, not a dump.

Every change committed

Each memory write is a git commit. Revert a bad one, diff two versions, see exactly when an agent knew what.

Branchable timelines

Fork the memory like a branch — spin up an experimental timeline and switch back when the experiment fails.

Local & private

No database, no cloud, no telemetry. A plain folder in your project. Copy it, move it, delete it — it’s yours.

Diffable & reviewable

Open a PR for your agent’s memory. Because decisions are data, they can be reviewed like code.

how it works

Three steps. No magic.

  1. 01

    Install & initialize

    One command creates a memory store in .mnemo/ — a tiny git repo inside your project.

  2. 02

    The agent writes memory

    Via the OpenCode plugin, an MCP tool, or mm new. Every write is auto-committed to git.

  3. 03

    Next session recalls

    At session start the agent gets the highlights; when it needs details, recall fetches the top ranked memories.

live demo

Watch it remember

Two sessions, one brain. The agent decides in the first — and recalls the decision in the second.

Animated demo: mnemo captures a decision in one OpenCode session and recalls it in the next
Recorded with vhs — reproduce it anytime with scripts/demo.tape

get started

Up and running in 30 seconds

npm install
$ npm i -g mnemo-mem
$ mm init
created .mnemo/

$ mm setup-opencode
installed plugin → ~/.config/opencode/plugins/mnemo.js
configured MCP → opencode.json
restart OpenCode for the plugin and MCP server to load
OpenCode MCP config
// opencode.json
{
  "mcp": {
    "mnemo": {
      "type": "local",
      "command": ["mm", "mcp"],
      "enabled": true
    }
  }
}
Every tool your agent needs to persist and recall — remember, recall, search, list, forget, status — exposed over MCP. Works with any agent that speaks MCP.

Stop repeating yourself.
Let the agent remember.