v2.1 — research preview

The second brain
that thinks like you.

A knowledge corpus that captures your decisions, voice, and relationships while you work. Read by every AI agent. Yours forever.

Markdown · plain text, forever Git · own your history Vendor-neutral · works with every agent
~/my-brain · nanobrain
nanobrain CLI demo: querying brain status, who, list, show, works with.

This isn't memory. It's a knowledge corpus.

Memory is "what did I say last Tuesday." Vendor memory features handle that fine.

The actual problem is your knowledge corpus lives half in your head, half in scattered notes, half in a thousand AI sessions you can't get back. Your voice. Your taste. The decisions you've made and the why behind them. Your relationships and how you talk to each one. Every AI agent you start fresh has to be brought up to speed.

nanobrain captures that corpus while you work, distills it in your voice, and lets every agent read it. The brain builds itself. You don't have to remember to remember.

how it works

Three layers. Always-on capture. Idle-time distill.

01

Capture

Every Claude Code session fires a hook. The hook does one thing: append a 50-millisecond pointer to a queue. No LLM, no commit, no waiting. You never feel it.

02

Distill

A background drainer wakes every 30 minutes. It checks if you're idle. If you're typing, it skips. If you've been quiet for 5+ minutes, it pulls one session from the queue and distills it into your brain — in your voice.

03

Query

/brain who is jane. /brain links ledger. Or wire any agent (Claude, Cursor, Codex, Gemini, Aider) through MCP — they all read the same markdown, context-filtered.

Claude session →   ┌────────────────────────────────────────────┐
  Gmail thread →   │  hook: 50ms pointer → queue/*.pending     │
  Calendar     →   │  drainer (idle): distill → brain/*.md     │
  Slack        →   │  graph: [[wikilinks]] auto-indexed        │
                   └────────────────────────────────────────────┘
                                       │
                                       ▼
                       /brain who is jane
                       /brain links project-x
                       /brain spawn branding-agent
why it's different

Every other "memory" tool locks you in. This one outlives them.

nanobrain Claude Memory ChatGPT Memory Mem0 / Letta Notion AI
Plain markdown
Works without internet
You own the data
Readable in 50 years
Multi-agent (Claude / Cursor / Codex / Gemini)
Greppable from your terminal
Open source● MITmixed
17 commands

Five you'll use daily. Twelve more when you need them.

/brain

Query the brain. Who is X. What's connected to Y. Where does Z live.

/brain-save

Force-save a decision or learning mid-session. Routes to the right file, redacts secrets, commits.

/brain-spawn

Mint a specialized agent with declared scope. Branding agent on the work side. Investing agent on the personal side. Each one boundary-locked.

/brain-doctor

Health check. Sources, contexts, GitHub sync, queue state, failed entries with retry hints.

/brain-restore

Non-destructive time travel. Branches from any git tag. Never resets, never force-pushes, never destroys current work.

And twelve more — ingest, distill, init, index, log, lint, graph, hash, compact, evolve, checkpoint, redact

/brain-ingest · pull one source into INBOX

/brain-distill · distill INBOX entries into brain files

/brain-init · scaffold a new brain

/brain-index · rebuild the entity catalog

/brain-log · append one operation line, greppable

/brain-lint · catch orphan pages, broken refs, missing tags

/brain-graph · rebuild [[wikilink]] backlink index

/brain-hash · integrity check via BRAIN_HASH.txt

/brain-compact · weekly cleanup, archives stale entries

/brain-evolve · monthly self-improvement proposal

/brain-checkpoint · force-capture mid-session

/brain-redact · scrub a leaked secret from history

bootstrap

Two minutes to install. The brain takes it from there.

01
# Clone the framework
git clone https://github.com/siddsdixit/nanobrain ~/nanobrain
02
# Create a PRIVATE repo for YOUR brain content
gh repo create my-brain --private --clone
03
# Install (capture hooks + idle distill drainer + skills)
bash ~/nanobrain/install.sh ~/my-brain \
  --work you@company.com \
  --personal you@gmail.com \
  --gh-repo my-brain
04
# Use Claude Code normally. Step away at some point.
# A few minutes after you go idle:
cat ~/my-brain/brain/decisions.md

Capture wires into Claude Code's Stop, SessionEnd, and PreCompact hooks — each is a sub-50ms file append, invisible to you. The distill drainer runs every 30 min via launchd, but only does LLM work when your keyboard's been idle for 5+ minutes. The brain builds itself in the background. You never wait on it.

works with

Read from any agent. Capture from Claude today, the rest in v2.2.

Claude Code

Native capture via Stop hook.
Read via MCP.

read · capture

Codex CLI

Read via MCP today.
Capture wrapper in v2.2.

read

Cursor

Read via MCP today.
Capture wrapper in v2.2.

read

Gemini CLI

Read via MCP today.
Capture wrapper in v2.2.

read

Aider

Read via MCP today.
Capture wrapper in v2.2.

read
lineage

Built on Karpathy's LLM Wiki pattern.

In April 2026, Andrej Karpathy described the pattern: three-layer corpus (raw / wiki / schema), immutable raw firehose, LLM-owned wiki, schema co-evolution via ADRs, git-native, source-dated entries.

What Karpathy described as a personal practice, nanobrain ships as a framework: same structure, same discipline, plus the capture loop, lint, index, log, and graph machinery that keep the corpus honest at scale.

  • Karpathy's autoresearch · git history as agent memory
  • Vannevar Bush's memex (1945) · the original associative trail
  • Obsidian, Logseq, Roam · wikilinks as a primitive

Stop teaching every agent who you are.

Capture once. Read everywhere. Forever.