open source · mit · llm-agnostic

Your second brain is a folder of Markdown files.

KeepMind stores everything — facts, lessons, skills, CRM, decisions, flashcards — as plain Markdown in a GitHub repo you own, and connects any LLM to it through MCP: Claude, Codex, GPT, Gemini, Grok, Ollama, or a local llama.cpp model running fully offline. Swap models anytime; the memory stays.

macOS · Windows · Linux · VPS · bot VM — a GitHub repo is the only requirement

long-term/facts.mdmemory/long-term
---
tier: long-term
updated: 2026-11-08
---

# Durable facts

- Prefers async updates; dislikes meetings
  without agendas [[Atlas]]
- Decision: ship Atlas API v1 in Q1 —
  logged in [[decisions]]
- Skill: weekly review template lives in
  [[skills/weekly-review]]
- ⚠ stale: pricing note expired 2026-10-01
$ npx keepmind-mcp
keepmind-mcp v0.1.1 · root: ~/keepmind
✓ sb_search   semantic + lexical
✓ sb_remember append-only writes
✓ sb_query    tasks · notes · crm
ready — any MCP client can connect
you/keepmind-repo/
├── short-term/   # daily raw logs
├── medium-term/  # weekly consolidations
├── long-term/    # facts · lessons · skills
├── entities/     # [[wikilinks]] + backlinks
├── skills/       # procedural memory
├── crm/          # people · companies
├── review/       # flashcards · spaced rep
├── ops/          # gaps · activity journal
└── sleep/        # nightly learning reports
// the repo is the brain

LLMs are runtimes.
The repo is the memory.

Every note, insight, task and entity is a file in a private repo only you control — synced both ways before every chat. Claude writes today, Grok answers tomorrow, a local model runs offline next week. Same memory, any engine.

  • Append-only writes — agents never overwrite; history is the audit trail
  • Procedural skills/ — workflows that survive switching models entirely
  • Search-gap log — unanswered queries become tomorrow's learning targets
  • Frontmatter validity — notes can expire; stale knowledge gets penalized in search
// spec sheet

What it actually does.

Not a note-taking app with an AI tab. A memory engine with tiers, consolidation, governance and a fast local decision layer.

01Tiered memoryShort, medium and long-term tiers modeled on human memory — raw logs consolidate upward on a schedule.
02Sleep-cycle learningNightly review distills the day into facts, lessons, skills and flashcards — plus a 5-question self-interrogation.
03Entity graphRecurring people, projects and topics get linked entities/ pages with automatic backlinks — a knowledge graph in plain Markdown.
04Procedural skills + CRMskills/ stores reusable workflows; crm/ keeps people, companies and interactions structured for any agent to read.
05Laya fast decisionsA local ONNX "System 1" engine (~33ms) classifies inbox items, routes memory writes and reranks search — no LLM round-trip.
06Semantic + lexical searchHybrid RAG: local embeddings (BGE/Nomic via llama.cpp) blended with keyword scoring, section-aware chunks, stale-note penalties.
07Natural automations"Every day at 8am summarize my WhatsApp" becomes a cron — in AUTO mode or queued for your approval, per job.
08MCP connectorsWhatsApp (QR), Telegram and Postgres bundled; any custom MCP server over stdio. External agents get the same memory via keepmind-mcp.
09Security auditScheduled scans for leaked secrets across the whole vault — reports file:line, never the secret itself.
10Runs anywhereDesktop on macOS/Windows/Linux, headless on a VPS, or installed by a bot on its own VM via MCP.
// tiered recall

Remember like a brain,
not like a database.

tier 01 — working

Short-term

Daily raw logs — chats, captures, quick notes. The last ~10 days stay in context; everything older gets consolidated upward.

tier 02 — consolidating

Medium-term

Weekly digests where patterns emerge — recurring topics, open loops, things worth promoting to long-term before they're forgotten.

tier 03 — permanent

Long-term

Facts, lessons, skills and decisions — injected into every chat, deduplicated nightly, and audited for secrets weekly.

// any model, any agent

Not locked to one AI.
Not locked to one machine.

Point KeepMind at whatever LLM you have — a frontier API, your Codex login, a free Gemini key, or a GGUF on a VPS. External agents drive the same repo through the bundled MCP server, so a bot on its own VM gets identical persistent memory.

🏠 Local llama.cppoffline
🟢 Codex / ChatGPToauth
🧠 Claudepro / max
⚡ OpenAIapi
✨ Geminiapi
𝕏 Grokapi
🦙 Ollamalocal
🔌 Any MCP agentstdio

Via MCP

Agents that speak MCP get sb_search, sb_remember, sb_query as native tools — zero prompt engineering.

Via repo + prompt

Any agent with GitHub access clones the repo and follows AGENTS.md — the scaffold ships ready-made configs for Claude, Codex, Cursor and Gemini.

Via headless

Run the whole brain on a VPS or a bot VM — crons keep learning while you sleep; wake up to a smarter vault.

// setup

Running in minutes.

Create the repo

KeepMind scaffolds a private GitHub repo with the full memory layout, agent configs and the MCP server — one click.

Connect a model

Sign in with Codex/Claude, paste an API key, or let bundled llama.cpp download a local model. Everything stays on your machine.

Let it learn

Chat captures memories automatically. Sleep cycles consolidate nightly; automations handle summaries, reviews and security audits on cron.

// install

Free forever.
MIT licensed.

Download the latest release — or clone the repo and run it. All it needs is a GitHub repo to call home.

macOS dmg / zip Download
Windows x64 + ARM64 · exe Download
Linux x64 · AppImage Download

or git clone + npm run dev — see the README