ClawVaultAI Agent Memory System

An Elephant Never Forgets

ClawVault is an open-source AI agent memory system with observational memory and a typed memory graph — it watches conversations, extracts what matters, and builds structured knowledge automatically. Context persistence, semantic search via qmd, context profiles, and zero cloud dependency.

terminal
$npm install -g clawvault
ClawVault - Memory vault for AI agents

“Let me explain the project again...”

Every time your AI agent restarts, it forgets everything. Decisions you made. Context you built. Lessons you learned together. You start from zero, every single time.

ClawVault changes that. Give your agent a memory vault where knowledge persists, accumulates, and grows.

How ClawVault AI Agent Memory Works

Observe conversations, extract knowledge, search by meaning, survive context death.

I

Observe & Compress

ClawVault watches your agent's conversations and compresses them into scored observations with type tags. Decisions, preferences, and lessons are extracted automatically — no manual saving needed.

# Auto-compress a session transcript
$clawvault observe --compress session.jsonl
# Output: scored observations
[decision|c=0.95|i=0.90] [[PostgreSQL]] chosen over [[MongoDB]]
[preference|c=0.82|i=0.60] [[Sarah]] prefers REST over GraphQL
[milestone|c=0.78|i=0.45] Dashboard feature deployed
II

Search by Meaning

Ask natural language questions. Powered by qmd with BM25 + vector embeddings + neural reranker for accurate results even when exact keywords don't match.

$clawvault vsearch "what database did we pick?"
III

Auto-Checkpoint & Wake

The OpenClaw hook auto-checkpoints before session resets and detects context death on startup. Your agent wakes up knowing what happened — including observation summaries.

# Hook auto-checkpoints on /new
# On next startup, if death detected:
$clawvault wake
# → Recovery alert + observation summaries
$clawvault graph
# → Traverse memory graph for related knowledge
$clawvault context --profile planning
# → Inject strategic context for planning mode
$clawvault compat
# → Check vault compatibility

ClawVault Commands. Infinite Memory.

Everything your AI agent needs to remember: persistent memory, semantic search, and dependable context recovery.

Observational Memory

Observational Memory

Your agent watches its own conversations and extracts what matters. Decisions (🔴), preferences (🟡), and progress (🟢) are auto-compressed and routed to vault categories — no manual saving required.

Semantic Search via qmd

Semantic Search via qmd

Find memories by meaning, not just keywords. Powered by qmd with BM25 keyword matching, vector embeddings, and a neural reranker for best-quality results.

Structured Categories

Structured Categories

Observations auto-route to decisions, people, projects, lessons, and more. Entity-slug routing puts Pedro's notes in people/pedro/. Everything has a place.

Context Death Resilience

Context Death Resilience

The OpenClaw hook auto-checkpoints before /new and detects context death on startup. Wake up with full awareness of where you left off — automatically.

Memory Graph

Memory Graph

Typed knowledge graph maps wiki-links, tags, and frontmatter relations between vault entries. Context retrieval traverses the graph to pull related knowledge — not just keyword matches.

Context Profiles

Context Profiles

Four retrieval presets — default, planning, incident, handoff — tune what context your agent sees. Planning mode pulls strategic context; incident mode focuses on recent events and blockers.

CLI First, Zero Cloud

CLI First, Zero Cloud

100% local filesystem. Zero network calls by default. No database, no server, no daemon. Works offline, works air-gapped. Your data never leaves your machine.

Open Source

Open Source

MIT licensed, fully transparent. Human-readable markdown storage, git-friendly, Obsidian-compatible. You always own your data.

ClawVault AI Agent Memory FAQ

01What makes ClawVault™ different from other memory solutions?
Observational memory. Most tools make you manually save things. ClawVault watches your agent's conversations and automatically extracts decisions, preferences, and lessons — compressed with emoji priorities (🔴/🟡/🟢) and routed to structured vault categories. Combined with qmd for BM25+vector+reranker search, it's a complete memory system.
02How does semantic search work?
ClawVault integrates with qmd, which provides a full search pipeline: BM25 keyword matching, vector embeddings for semantic similarity, and a neural reranker for accuracy. Ask 'what database did we choose?' and get relevant results even if you never used those exact words.
03Does ClawVault make any network calls?
Zero by default. The only feature that contacts an external API is 'observe --compress', which sends session text to Gemini Flash for LLM compression — and only when you explicitly set GEMINI_API_KEY. Without the key, it uses a rule-based fallback. No telemetry, no analytics, no phone-home. Ever.
04Does it work with any AI agent framework?
Yes. ClawVault is framework-agnostic. If your agent can run shell commands, it can use ClawVault. It has first-class OpenClaw integration (opt-in hook for auto-checkpoint and context death detection), but works with LangChain, AutoGPT, custom agents, or any CLI-based workflow.
05How do I recover from context death?
With the OpenClaw hook enabled, it's automatic — checkpoint before /new, detect death on startup, inject recovery alert. Without the hook, run 'clawvault checkpoint' before risky operations and 'clawvault wake' to restore context. The handoff system ensures nothing is ever truly lost.
06What is observational memory?
Instead of manually saving memories, ClawVault's observer watches session transcripts and compresses them into scored observations with type tags (decision, commitment, milestone, lesson, etc.) and importance scores. High-importance observations route automatically to vault categories with wiki-links. Raw transcripts are preserved as a ledger for replay and rebuild.
07What is the memory graph?
ClawVault builds a typed knowledge graph from wiki-links, tags, and frontmatter relations in your vault. When you query context, it doesn't just find matching documents — it traverses the graph to include related knowledge, giving your agent richer understanding.
08What are context profiles?
Context profiles are retrieval presets that tune what memories get injected. Use 'planning' for strategic work, 'incident' for debugging/crisis mode, 'handoff' for session transitions. Run 'clawvault context --profile planning' to try it.

“The best agents don't just respond. They remember.”