Persistent memory engine for AI coding agents.
mnemos
Your AI agent has the memory of a goldfish. Mnemos fixes that.
A persistent memory engine for AI coding agents.
Mnemos gives Claude Code, Kiro, Cursor, Windsurf, and other MCP clients a memory that survives across sessions: architecture decisions, bug root causes, project conventions, and non-obvious implementation details.
Single Go binary. Embedded SQLite. Zero runtime dependencies. No Docker. No cloud. No Python. No Node.
Agent (Claude Code / Kiro / Cursor / Windsurf / ...)
↓ MCP stdio
mnemos serve
↓
SQLite + FTS5 (~/.mnemos/mnemos.db)
What does it actually do?
Every time your agent learns something worth keeping, it stores it in Mnemos. Next session, it can pull that context back before it starts coding.
That means:
- fewer repeated explanations
- less re-discovery of old bugs and decisions
- more continuity across sessions
- better context for long-running projects
No more re-explaining your project structure every Monday morning. No more rediscovering the same environment quirk three times in one week.
The memory lifecycle:
- Agent finishes something meaningful (fixed a bug, made a decision, learned a pattern)
- Calls
mnemos_storewith the content - Mnemos deduplicates, classifies, and indexes it
- Next session:
mnemos_contextassembles relevant memories within a token budget - Agent picks up right where it left off
Why it feels different
Mnemos is built for real coding workflows, not just generic note storage.
MCP-native: designed to be called directly by coding agentsFast to install: one binary, one local databaseActually useful retrieval: FTS + optional semantic search + context assemblyLifecycle aware: deduplication, relevance decay, archive/GCReadable by humans too: optional Markdown mirrorAutopilot ready: one setup command wires hooks + steering for Claude, Kiro, or Cursor
Quick Start
# install
curl -fsSL https://raw.githubusercontent.com/mnemos-dev/mnemos/main/install.sh | bash
# first-time setup
mnemos init
# run as MCP server
mnemos serve
Then wire it to your AI client — or use autopilot setup to make it fully automatic.
Autopilot Setup
Mnemos is an MCP server, not an agent controller. By default, the agent only uses memory if it's instructed to. Autopilot closes that gap: one command injects hook config, steering files, and MCP config so the agent uses memory automatically on every session — no reminding needed.
# Claude Code
mnemos setup claude
# Kiro
mnemos setup kiro
# Cursor
mnemos setup cursor
That's it. From that point:
- Session start — Mnemos automatically loads relevant context into the agent's window
- During work — Mnemos searches memory when the topic changes
- Session end — Mnemos verifies memory was captured and cleans up state
Use --global to install for all projects instead of just the current one:
mnemos setup claude --global
Use --force to overwrite existing config files without prompting:
mnemos setup claude --force
What `mnemos setup` writes
Claude Code (mnemos setup claude):
| File | Purpose |
|---|---|
CLAUDE.md |
Steering instructions — tells Claude when and what to store |
.claude/hooks.json |
Hook config — wires session-start, prompt-submit, session-end |
.mcp.json |
MCP server config — registers mnemos serve |
Kiro (mnemos setup kiro):
| File | Purpose |
|---|---|
.kiro/steering/mnemos.md |
Steering file — auto-loaded by Kiro on every session |
.kiro/mcp.json |
MCP server config |
Cursor (mnemos setup cursor):
| File | Purpose |
|---|---|
.cursorrules |
Steering instructions for Cursor |
.mcp.json |
MCP server config |
How autopilot works under the hood
Autopilot uses two complementary systems:
Hooks (deterministic) — mnemos hook session-start/prompt-submit/session-end
These are short-lived processes called by the AI client at specific lifecycle events. They run in InitLight mode (no background workers, cold start < 50ms) and always exit 0 — they never interrupt the agent session.
session-start: assembles relevant context from Mnemos and injects it into the agent's windowprompt-submit: detects topic changes using Jaccard similarity; searches memory when the topic shifts; respects a 5-minute cooldown per topic to avoid noisesession-end: counts memories stored during the session; optionally leaves a breadcrumb; cleans up session state
Steering (LLM-guided) — CLAUDE.md / .kiro/steering/mnemos.md / .cursorrules
These files instruct the agent on what to store and when. The agent makes the semantic judgment — hooks handle the mechanical retrieval.
Session start → hook injects context → agent reads it
During work → hook searches on topic change → agent receives results
→ agent discovers durable learning → agent ca
Tools (2)
mnemos_storeStores content into the memory engine for future retrieval.mnemos_contextAssembles relevant memories within a token budget for the current session.Configuration
{"mcpServers": {"mnemos": {"command": "mnemos", "args": ["serve"]}}}