clawvault
Structured memory system for OpenClaw agents. Context death resilience (checkpoint/recover), structured storage, Obsidian-compatible markdown, and local semantic search.
Install
mkdir -p .claude/skills/clawvault && curl -L -o skill.zip "https://mcp.directory/api/skills/download/3884" && unzip -o skill.zip -d .claude/skills/clawvault && rm skill.zipInstalls to .claude/skills/clawvault
About this skill
ClawVault 🐘
An elephant never forgets. Structured memory for OpenClaw agents.
Built for OpenClaw. Canonical install: npm CLI + hook install + hook enable.
Security & Transparency
What this skill does:
- Reads/writes markdown files in your vault directory (
CLAWVAULT_PATHor auto-discovered) repair-sessionreads and modifies OpenClaw session transcripts (~/.openclaw/agents/) — creates backups before writing- Provides an OpenClaw hook pack (
hooks/clawvault/handler.js) with lifecycle events (gateway:startup,gateway:heartbeat,command:new,session:start,compaction:memoryFlush,cron.weekly). Hook is opt-in and must be installed/enabled. observe --compressmakes LLM API calls (Gemini Flash by default) to compress session transcripts into observations
Environment variables used:
CLAWVAULT_PATH— vault location (optional, auto-discovered if not set)OPENCLAW_HOME/OPENCLAW_STATE_DIR— used byrepair-sessionto find session transcriptsGEMINI_API_KEY— used byobservefor LLM compression (optional, only if using observe features)
No cloud sync — all data stays local. No network calls except LLM API for observe compression.
This is a full CLI tool, not instruction-only. It writes files, registers hooks, and runs code.
Auditability: the published ClawHub skill bundle includes SKILL.md, HOOK.md, and hooks/clawvault/handler.js so users can inspect hook behavior before enabling it.
Install (Canonical)
npm install -g clawvault
openclaw hooks install clawvault
openclaw hooks enable clawvault
# Verify and reload
openclaw hooks list --verbose
openclaw hooks info clawvault
openclaw hooks check
# restart gateway process
clawhub install clawvault can install skill guidance, but does not replace explicit hook pack installation.
Recommended Safe Install Flow
# 1) Review package metadata before install
npm view clawvault version dist.integrity dist.tarball repository.url
# 2) Install CLI + qmd dependency
npm install -g clawvault@latest
npm install -g github:tobi/qmd
# 3) Install hook pack, but DO NOT enable yet
openclaw hooks install clawvault
# 4) Review hook source locally before enabling
node -e "const fs=require('fs');const p='hooks/clawvault/handler.js';console.log(fs.existsSync(p)?p:'hook file not found in current directory')"
openclaw hooks info clawvault
# 5) Enable only after review
openclaw hooks enable clawvault
openclaw hooks check
Setup
# Initialize vault (creates folder structure + templates)
clawvault init ~/my-vault
# Or set env var to use existing vault
export CLAWVAULT_PATH=/path/to/memory
# Optional: shell integration (aliases + CLAWVAULT_PATH)
clawvault shell-init >> ~/.bashrc
Quick Start for New Agents
# Start your session (recover + recap + summary)
clawvault wake
# Capture and checkpoint during work
clawvault capture "TODO: Review PR tomorrow"
clawvault checkpoint --working-on "PR review" --focus "type guards"
# End your session with a handoff
clawvault sleep "PR review + type guards" --next "respond to CI" --blocked "waiting for CI"
# Health check when something feels off
clawvault doctor
Reality Checks Before Use
# Verify runtime compatibility with current OpenClaw setup
clawvault compat
# Verify qmd is available
qmd --version
# Verify OpenClaw CLI is installed in this shell
openclaw --version
ClawVault currently depends on qmd for core vault/query flows.
Current Feature Set
Memory Graph
ClawVault builds a typed knowledge graph from wiki-links, tags, and frontmatter:
# View graph summary
clawvault graph
# Refresh graph index
clawvault graph --refresh
Graph is stored at .clawvault/graph-index.json — schema versioned, incremental rebuild.
Graph-Aware Context Retrieval
# Default context (semantic + graph neighbors)
clawvault context "database decision"
# With a profile preset
clawvault context --profile planning "Q1 roadmap"
clawvault context --profile incident "production outage"
clawvault context --profile handoff "session end"
# Auto profile (used by OpenClaw hook)
clawvault context --profile auto "current task"
Context Profiles
| Profile | Purpose |
|---|---|
default | Balanced retrieval |
planning | Broader strategic context |
incident | Recent events, blockers, urgent items |
handoff | Session transition context |
auto | Hook-selected profile based on session intent |
OpenClaw Compatibility Diagnostics
# Check hook wiring, event routing, handler safety
clawvault compat
# Strict mode for CI
clawvault compat --strict
Core Commands
Wake + Sleep (primary)
clawvault wake
clawvault sleep "what I was working on" --next "ship v1" --blocked "waiting for API key"
Store memories by type
# Types: fact, feeling, decision, lesson, commitment, preference, relationship, project
clawvault remember decision "Use Postgres over SQLite" --content "Need concurrent writes for multi-agent setup"
clawvault remember lesson "Context death is survivable" --content "Checkpoint before heavy work"
clawvault remember relationship "Justin Dukes" --content "Client contact at Hale Pet Door"
Quick capture to inbox
clawvault capture "TODO: Review PR tomorrow"
Search (requires qmd installed)
# Keyword search (fast)
clawvault search "client contacts"
# Semantic search (slower, more accurate)
clawvault vsearch "what did we decide about the database"
Context Death Resilience
Wake (start of session)
clawvault wake
Sleep (end of session)
clawvault sleep "what I was working on" --next "finish docs" --blocked "waiting for review"
Checkpoint (save state frequently)
clawvault checkpoint --working-on "PR review" --focus "type guards" --blocked "waiting for CI"
Recover (manual check)
clawvault recover --clear
# Shows: death time, last checkpoint, recent handoff
Handoff (manual session end)
clawvault handoff \
--working-on "ClawVault improvements" \
--blocked "npm token" \
--next "publish to npm, create skill" \
--feeling "productive"
Recap (bootstrap new session)
clawvault recap
# Shows: recent handoffs, active projects, pending commitments, lessons
Auto-linking
Wiki-link entity mentions in markdown files:
# Link all files
clawvault link --all
# Link single file
clawvault link memory/2024-01-15.md
Folder Structure
vault/
├── .clawvault/ # Internal state
│ ├── last-checkpoint.json
│ └── dirty-death.flag
├── decisions/ # Key choices with reasoning
├── lessons/ # Insights and patterns
├── people/ # One file per person
├── projects/ # Active work tracking
├── handoffs/ # Session continuity
├── inbox/ # Quick captures
└── templates/ # Document templates
Best Practices
- Wake at session start —
clawvault wakerestores context - Checkpoint every 10-15 min during heavy work
- Sleep before session end —
clawvault sleepcaptures next steps - Use types — knowing WHAT you're storing helps WHERE to put it
- Wiki-link liberally —
[[person-name]]builds your knowledge graph
Checklist for AGENTS.md
## Memory Checklist
- [ ] Run `clawvault wake` at session start
- [ ] Checkpoint during heavy work
- [ ] Capture key decisions/lessons with `clawvault remember`
- [ ] Use wiki-links like `[[person-name]]`
- [ ] End with `clawvault sleep "..." --next "..." --blocked "..."`
- [ ] Run `clawvault doctor` when something feels off
Append this checklist to existing memory instructions. Do not replace your full AGENTS.md behavior unless you intend to.
Session Transcript Repair (v1.5.0+)
When the Anthropic API rejects with "unexpected tool_use_id found in tool_result blocks", use:
# See what's wrong (dry-run)
clawvault repair-session --dry-run
# Fix it
clawvault repair-session
# Repair a specific session
clawvault repair-session --session <id> --agent <agent-id>
# List available sessions
clawvault repair-session --list
What it fixes:
- Orphaned
tool_resultblocks referencing non-existenttool_useIDs - Aborted tool calls with partial JSON
- Broken parent chain references
Backups are created automatically (use --no-backup to skip).
Troubleshooting
- qmd not installed — install qmd, then confirm with
qmd --version - No ClawVault found — run
clawvault initor setCLAWVAULT_PATH - CLAWVAULT_PATH missing — run
clawvault shell-initand add to shell rc - Too many orphan links — run
clawvault link --orphans - Inbox backlog warning — process or archive inbox items
- "unexpected tool_use_id" error — run
clawvault repair-session - OpenClaw integration drift — run
clawvault compat - Hook enable fails / hook not found — run
openclaw hooks install clawvault, thenopenclaw hooks enable clawvault, restart gateway, and verify viaopenclaw hooks list --verbose - Graph out of date — run
clawvault graph --refresh - Wrong context for task — try
clawvault context --profile incidentor--profile planning
Stability Snapshot
- Typecheck passes (
npm run typecheck) - Test suite passes (
449/449) - Cross-platform path handling hardened for Windows in:
- qmd URI/document path normalization
- WebDAV path safety and filesystem resolution
- shell-init output expectations
- OpenClaw runtime wiring validated by
clawvault compat --strict(requires localopenclawbinary for full runtime validation)
Integration with qmd
ClawVault uses qmd for search:
# Install qmd
bun install -g github:tobi/qmd
# Alternative
npm install -g github:tobi/qmd
# Add vault
---
*Content truncated.*
More by openclaw
View all skills by openclaw →You might also like
flutter-development
aj-geddes
Build beautiful cross-platform mobile apps with Flutter and Dart. Covers widgets, state management with Provider/BLoC, navigation, API integration, and material design.
drawio-diagrams-enhanced
jgtolentino
Create professional draw.io (diagrams.net) diagrams in XML format (.drawio files) with integrated PMP/PMBOK methodologies, extensive visual asset libraries, and industry-standard professional templates. Use this skill when users ask to create flowcharts, swimlane diagrams, cross-functional flowcharts, org charts, network diagrams, UML diagrams, BPMN, project management diagrams (WBS, Gantt, PERT, RACI), risk matrices, stakeholder maps, or any other visual diagram in draw.io format. This skill includes access to custom shape libraries for icons, clipart, and professional symbols.
godot
bfollington
This skill should be used when working on Godot Engine projects. It provides specialized knowledge of Godot's file formats (.gd, .tscn, .tres), architecture patterns (component-based, signal-driven, resource-based), common pitfalls, validation tools, code templates, and CLI workflows. The `godot` command is available for running the game, validating scripts, importing resources, and exporting builds. Use this skill for tasks involving Godot game development, debugging scene/resource files, implementing game systems, or creating new Godot components.
ui-ux-pro-max
nextlevelbuilder
"UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient."
nano-banana-pro
garg-aayush
Generate and edit images using Google's Nano Banana Pro (Gemini 3 Pro Image) API. Use when the user asks to generate, create, edit, modify, change, alter, or update images. Also use when user references an existing image file and asks to modify it in any way (e.g., "modify this image", "change the background", "replace X with Y"). Supports both text-to-image generation and image-to-image editing with configurable resolution (1K default, 2K, or 4K for high resolution). DO NOT read the image file first - use this skill directly with the --input-image parameter.
fastapi-templates
wshobson
Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.
Related MCP Servers
Browse all serversOrchestrate complex problem-solving with our multi agent system—specialized agents offer deep, structured, and parallel
Memory Bank offers persistent project context with structured markdown files, workflow guidance, and automatic timestamp
Think Tool is a powerful knowledge management system for explicit reasoning, policy verification, and safe knowledge dat
Maintain, search, and update structured markdown documents with syntax support. Export to PDF and integrate with mkdocs
Memory Bank: structured development workflow software with five modes to keep persistent project state and context acros
Enhance software testing with Playwright MCP: Fast, reliable browser automation, an innovative alternative to Selenium s
Stay ahead of the MCP ecosystem
Get weekly updates on new skills and servers.