Local-first memory layer for OpenClaw, Codex App, and Codex CLI: capture, recall, dedupe, and native sync.
# Add to your Claude Code skills
git clone https://github.com/legendaryvibecoder/gigabrainGigabrain is a local-first memory stack for OpenClaw agents, Codex App, Codex CLI, Claude Code, and Claude Desktop. It converts conversations and native notes into durable, queryable memory, then injects the right context before each prompt so agents stay consistent across sessions.
Built for production use: SQLite-backed recall, deterministic dedupe/audit flows, native markdown sync, world model, Obsidian surface, and an optional web console for memory operations.
| Host surface | Install | What Gigabrain owns |
| --- | --- | --- |
| OpenClaw | openclaw plugins install | Registry, native sync, recall orchestration, audit/nightly, memory-slot provider |
| Codex App / CLI | npm install + setup | Shared project/user memory store, MCP tools, checkpoints, maintenance |
| Claude Code | npm install + setup | Shared project/user memory store, MCP tools, managed .mcp.json wiring |
| Claude Desktop | claude:desktop:bundle | Same MCP-backed memory store and tools as Claude Code |
openclaw plugins install @legendaryvibecoder/gigabrain
cd ~/.openclaw/extensions/gigabrain && npm run setup -- --workspace /path/to/workspace
npx gigabrainctl doctor --config ~/.openclaw/openclaw.json
npm install @legendaryvibecoder/gigabrain
npx gigabrain-codex-setup --project-root /path/to/repo
.codex/actions/verify-gigabrain.sh
No comments yet. Be the first to share your thoughts!
npm install @legendaryvibecoder/gigabrain
npx gigabrain-claude-setup --project-root /path/to/repo
.claude/actions/verify-gigabrain.sh
Upgrading? See the upgrade guide.
Conversation (OpenClaw / Codex / Claude Code / Claude Desktop)
│
▼
┌──────────────────────────────────┐
│ Gigabrain │
│ (memory layer + MCP server) │
├──────────────────────────────────┤
│ Capture ─► Policy ─► Registry │
│ Recall ◄─ Orchestrator │
│ Native Sync ◄─► MEMORY.md │
│ World Model (entities/beliefs) │
│ Vault Mirror ─► Obsidian │
└──────────────┬───────────────────┘
│
SQLite + FTS5
gigabrain_recall, gigabrain_remember, gigabrain_checkpoint, gigabrain_provenance, gigabrain_recent, gigabrain_doctor, gigabrain_entity, gigabrain_contradictions, gigabrain_relationshipsMEMORY.md and daily notes alongside the registry for unified recall| Subsystem | Description | Docs | |-----------|-------------|------| | Sharing model | Multi-host sharing modes and scope rules | docs/sharing.md | | Configuration | Full config reference (runtime, capture, recall, dedupe, LLM, vault, quality) | docs/configuration.md | | Memory protocol | Capture tags, agent instructions, AGENTS.md | docs/memory-protocol.md | | Recall pipeline | 11-step orchestrated recall with strategy selection | docs/recall.md | | Obsidian surface | Vault structure, setup, pull workflow | docs/obsidian.md | | Nightly maintenance | Pipeline steps, artifacts, scheduling | docs/maintenance.md |
node:sqlite experimental API)v0.6.x memory surface)npx gigabrainctl nightly # Full nightly pipeline
npx gigabrainctl maintain # Maintenance only
npx gigabrainctl audit --mode shadow|apply # Quality audit
npx gigabrainctl inventory # Memory stats
npx gigabrainctl doctor # Health check
npx gigabrainctl world rebuild # Rebuild world model
npx gigabrainctl orchestrator explain --query "…" # Explain recall strategy
npx gigabrainctl synthesis build # Rebuild synthesis
npx gigabrainctl review contradictions # Inspect contradictions
npx gigabrainctl review open-loops # Inspect open loops
npx gigabrainctl vault build # Build Obsidian surface
npx gigabrainctl vault doctor # Vault health check
npx gigabrainctl vault report # Surface summary
npx gigabrainctl vault pull --host … --target … # Pull vault to laptop
All commands accept --config <path> and are also available as npm run scripts.
| Method | Path | Auth | Description |
|--------|------|------|-------------|
| GET | /gb/health | No | Health check |
| POST | /gb/recall | Token | Memory recall for a query |
| POST | /gb/suggestions | Token | Structured suggestion ingest |
| POST | /gb/bench/recall | Token | Recall benchmark endpoint |
| GET | /gb/memory/:id/timeline | Token | Event timeline for a memory |
| GET | /gb/evolution | Token | Entity evolution timeline by claim slot |
| GET | /gb/relationships | Token | Relationship graph with counterpart metadata |
Auth uses the X-GB-Token header. Fail-closed: no token configured = all requests rejected.
Optional FastAPI dashboard for browsing and managing memories. See memory_api/README.md.
npm test # All tests
npm run test:unit # Unit tests only
npm run test:integration # Integration tests
npm run test:regression # Regression tests
npm run test:performance # Performance tests
npm run test:release-live # Live Codex/OpenClaw smoke
npm run eval:deep-recall # Recall-routing evaluation
node bench/memorybench/run.js \
--base-url http://127.0.0.1:18789 \
--token "$GB_UI_TOKEN" \
--cases eval/cases.jsonl \
--topk 8 --runs 3
Results written to bench/memorybench/data/runs/.
gigabrain/
├── index.ts # Plugin entry point (OpenClaw extension)
├── openclaw.plugin.json # Config schema definition
├── package.json
│
├── lib/core/ # Core services
│ ├── config.js # Config validation and normalization
│ ├── capture-service.js # Extraction, dedup, registry upsert
│ ├── recall-service.js # Search, filter, inject pipeline
│ ├── event-store.js # Append-only event log
│ ├── projection-store.js # Materialized current-state view
│ ├── native-sync.js # MEMORY.md + daily notes indexer
│ ├── person-service.js # Entity mention graph
│ ├── policy.js # Junk filter, plausibility, retention rules
│ ├── audit-service.js # Quality scoring, review, restore/report
│ ├── maintenance-service.js # Nightly pipeline, snapshots, artifacts
│ ├── llm-router.js # LLM provider abstraction + task profiles
│ ├── vault-mirror.js # Obsidian surface builder + pull workflow
│ ├── http-routes.js # Gateway HTTP endpoints
│ ├── review-queue.js # Capture and audit review queue
│ └── metrics.js # Telemetry counters
│
├── scripts/ # CLI tools
│ ├── gigabrainctl.js # Main control plane
│ ├── migrate-v3.js # Schema migration
│ ├── harmonize-memory.js # Memory harmonization
│ └── vault-export.js # Direct vault surface build
│
├── doc