| name | mindgraph |
| description | Fingerprinted knowledge graph with reactive indexing. Use when user says "create a mind map", "build knowledge base", "ingest this", "search my wiki", "what do I know about X", "mindgraph", or "/mindgraph". Also triggers on "knowledge graph", "mind map", "wiki", "index this project".
|
MindGraph — Fingerprinted Knowledge Graph
Three-layer knowledge system. Reactive indexing.
Architecture
raw/ → Immutable source documents
wiki/ → LLM-compiled markdown articles (entity, topic, summary pages)
.mindgraph/ → SQLite + FTS5 fingerprint index (section-level)
Index: caveman briefs + section pointers. NEVER read whole wiki files — search first, read matched sections only.
Tools
<kb> = knowledge base root path.
| Command | Usage |
|---|
| init | python3 -m tools init <kb> [--mode standalone|project] |
| ingest | python3 -m tools ingest <kb> <source_file> |
| fingerprint | python3 -m tools fingerprint <kb> [--force] [--file path] |
| search | python3 -m tools search <kb> "query" [--limit N] [--verbose] |
| lint | python3 -m tools lint <kb> [--fix] |
| stats | python3 -m tools stats <kb> [--json] |
| learn | python3 -m tools learn <kb> "topic" [--json] |
| watch start | python3 -m tools watch <kb> start |
| watch stop | python3 -m tools watch <kb> stop |
| watch status | python3 -m tools watch <kb> status |
Workflows
Initialize Knowledge Base
User: "create mind map" / "start knowledge base":
- Ask: standalone or project?
- Run:
python3 -m tools init <path> --mode <mode>
- Start watcher:
python3 -m tools watch <path> start
- Report structure created
Ingest Source
User gives paper, article, URL, "ingest this":
- URL: download → save to raw/ first
- Run:
python3 -m tools ingest <kb> <source_file>
- Tool compiles wiki pages, updates index/log, fingerprints
- Report what created
Query Knowledge Base
User asks "what do I know about X":
- Search first:
python3 -m tools search <kb> "query terms"
- Read ONLY matched file:line_range sections
- Synthesize from matched sections
- Good answer: suggest new wiki page
Lint and Maintain
User: "check health" / issues noticed:
- Run:
python3 -m tools lint <kb>
- Report issues
- Offer fix:
python3 -m tools lint <kb> --fix
Real-Time Updates
Watcher handles fingerprints:
- File modified → changed sections re-fingerprinted
- New file → wiki node auto-generated + fingerprinted
- File deleted → DB entries cleaned
- No manual fingerprint needed
Rules
- Search before reading — query fingerprint index first
- Read sections, not files — use line ranges from search results
- Trust watcher — no manual fingerprint unless watcher stopped
- Follow schema — wiki pages need Summary, Details, References, See Also
- Log everything — all ops logged to wiki/log.md
- Cross-reference — use [[Page Name]] links between wiki pages
- Caveman briefs — index briefs compressed; expand mentally when reading
Token Efficiency
- Fingerprint index ~20-50KB for hundreds of articles
- Search returns relevant section pointers only
- Read specific line ranges, not whole 10KB+ wiki pages
- Multiple Claude sessions share index via .mindgraph/mindgraph.db