A multi-KB personal knowledge base powered by Claude Code. Obsidian-compatible markdown notes with agentic research, hybrid retrieval, link graph analysis, knowledge quality tracking, and MCP server for external tool access.
SynapseNotes is the machinery for building, querying, and maintaining a personal knowledge base through Claude Code. You ask questions, research topics, ingest sources β and the system produces atomic markdown notes with citations, wikilinks, and metadata. The notes are Obsidian-compatible, the search is TF-IDF + graph-augmented, and everything is exposed as an MCP server so other tools can query your knowledge.
The system is the infrastructure. The content is yours.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β YOU (Claude Code) β
β /kb-research /kb-search /kb-question /kb-ingest β
ββββββββββββ¬βββββββββββ¬βββββββββββ¬βββββββββββ¬ββββββββββββββββββ
β β β β
βββββββΌβββββββββββΌβββββββββββΌβββββββββββΌββββββ
β SynapseNotes Engine β
β βββββββββββ ββββββββββββ ββββββββββββββββ β
β β Search β β Linter β β Link Graph β β
β β TF-IDF β β Quality β β Patterns β β
β β + Graph β β Checks β β Contradicts β β
β βββββββββββ ββββββββββββ ββββββββββββββββ β
ββββββββββββ¬βββββββββββ¬βββββββββββ¬ββββββββββββ
β β β
ββββββββββββΌβββ βββββΌβββββ ββββΌβββββββββββ
β kbs/general β β kbs/ β β kbs/ β
β β βpersonalβ β <your- β
β β β privateβ β domain> β
β β β β β β
βββββββββββββββ ββββββββββ βββββββββββββββ
β β β
ββββββββββββΌβββββββββββΌβββββββββββΌββββββββββββ
β references/ (shared) β
β Structured source summaries with URLs β
βββββββββββββββββββββββββββββββββββββββββββββββ
β
βββββββββββββββββββββΌββββββββββββββββββββββββββ
β MCP Server (stdio) β
β kb_search kb_read kb_map kb_explore β
β Accessible from any Claude Code project β
βββββββββββββββββββββββββββββββββββββββββββββββ
You ask a question or research a topic
β
βββ Claude searches the web (concurrent agents, configurable depth)
βββ Saves source material to references/ (with source_type classification)
βββ Infers which KB to save to (from topic + existing coverage)
βββ Produces atomic notes with epistemic_status tracking
βββ Links everything with [[wikilinks]] and inline citations
βββ Indexes for hybrid search (TF-IDF + title boost + graph expansion)
βββ Detects patterns, contradictions, and gaps automatically
βββ Accessible from any project via MCP server
Notes are organized into multiple knowledge bases with different purposes and access levels:
kbs.yaml β Registry declaring all KBs (per-user, gitignored)
kbs/
general/ β Default KB (cross-cutting concepts, tools)
personal/ β Private notes (gitignored, excluded from MCP)
<your-domain>/ β Add domain KBs with /kb-init
The system automatically routes queries and notes to the right KB:
"domain-specific query"
β
ββββββββΌβββββββ
β KB Router β
β Check each β
β KB for best β
β match β
ββββ¬ββββββββ¬βββ
β β
Strong matchβ βNo clear match
in one KB β β
βΌ βΌ
βββββββββββββββ ββββββββββββ
β matched β β Unified β
β KB β β Index β
β (scoped) β β (all KBs)β
βββββββββββββββ ββββββββββββ
- Writes (
/kb-research,/kb-question): infer KB from topic β propose β user confirms - Reads (
/kb-search,/kb-explain): infer KB from query β auto-route or fall back to unified - Explicit (
--kb <name>): always overrides to specified KB
Every note tracks how confident we are in its claims:
Confidence Spectrum
verified ββββ likely ββββ speculative ββββ disputed ββββ opinion
β β β β β
Primary Credible Informed Conflicting Author's
sources, secondary inference, credible judgment,
raw data, analyses may change claims not
papers exist falsifiable
When synthesizing across notes, the system surfaces confidence:
- "Based on verified primary sources: X"
- "According to [author]'s analysis [opinion]: Y"
Reference files are classified by reliability:
| Source Type | Examples | Weight |
|---|---|---|
| primary | Original data, official post-mortems, academic papers, protocol/product docs | Highest |
| secondary | Analyses based on primary sources, firm reports, reputable journalism | High |
| opinion | Tweets, blog opinions, community commentary | Medium |
| unverified | News articles, aggregator summaries | Lowest |
User Query: "How does X work?"
β
βββββββββββΌββββββββββ
β KB Router β
β (infer best KB) β
βββββββββββ¬ββββββββββ
β
βββββββββββΌββββββββββ
β Multi-Query β
β Expansion β
β + reformulations β
βββββββββββ¬ββββββββββ
β
ββββββββββββββββΌβββββββββββββββ
βΌ βΌ βΌ
βββββββββββ ββββββββββββ βββββββββββ
β TF-IDF β β Title/ β β Dense β
β + meta β β Slug/ β β Embed β
β prepend β β Tag β β (opt) β
β β β Boost β β β
ββββββ¬βββββ ββββββ¬ββββββ ββββββ¬βββββ
β β β
ββββββββ¬ββββββββββββββββββββββ
β
ββββββββββΌβββββββββ
β RRF Fusion β
β (merge ranks) β
ββββββββββ¬βββββββββ
β
ββββββββββΌβββββββββ
β Graph Expansion β
β (1-hop wikilink β
β neighbors) β
ββββββββββ¬βββββββββ
β
ββββββββββΌβββββββββ
β Topic Weighting β
β (boost small β
β clusters) β
ββββββββββ¬βββββββββ
β
βΌ
Ranked Results
(with KB label +
epistemic status)
All thresholds are in .kb/config.yaml. The system includes an evaluation harness (tests/) with golden queries to measure Recall@5, MRR, and nDCG@5 after any infrastructure change.
The KB doesn't just store notes β it actively analyzes its own quality:
$ python3 .kb/kb-index.py patterns --kb my-domain
Detected patterns (4):
pattern-a (10 notes, NO synthesis note)
pattern-b (5 notes, NO synthesis note)
pattern-c (8 notes, HAS synthesis) β
pattern-d (15 notes, HAS synthesis) β$ python3 .kb/kb-index.py contradictions-scan --kb my-domain
Potential contradictions:
Topic X: value $A in note-1 vs $B in note-2
β reconcile or note context difference$ python3 .kb/kb-index.py gaps suggestions --kb my-domain
1. [HIGH] Synthesize "pattern-a" cluster (5 notes)
2. [HIGH] Synthesize "pattern-b" cluster (10 notes)
3. [MEDIUM] Add insights to cluster with 0 insight notes$ python3 .kb/kb-index.py gaps research
Unresolved research gaps (n across m hubs):
Research Hub: Topic A β 6 gaps
Research Hub: Topic B β 4 gaps| Skill | Purpose |
|---|---|
/kb-research <topic> |
Deep research: plan β web search β save references β create notes. Configurable depth (shallow/medium/deep). Auto-infers target KB. |
/kb-question <question> |
Quick Q&A saved as a note with epistemic status. |
/kb-ingest <file or URL> |
Extract atomic notes from source material. Classifies source type. |
/kb-note |
Capture insights from the current conversation. |
/kb-init |
Create a new knowledge base interactively. |
| Skill | Purpose |
|---|---|
/kb-search <query> |
Smart KB routing β tiered retrieval β multi-query expansion β grounded synthesis with epistemic transparency. |
/kb-explain <topic> |
Comprehensive narrative synthesis. Flags gaps. Saves as rewritable synthesis note with dependency tracking. |
| Skill | Purpose |
|---|---|
/kb-publish <note> |
Self-contained interactive HTML report with collapsible sections, footnotes, wikilink navigation. |
/kb-review |
Quality audit: lint, link graph, staleness, duplicates, tag sprawl, note size, research gaps, retrieval quality. |
/kb-move |
Migrate notes between KBs with cross-reference updates. |
---
title: Note Title
tags: [tag1, tag2]
created: 2026-04-20
updated: 2026-04-20
type: concept | question | reference | insight | synthesis
epistemic_status: verified | likely | speculative | disputed | opinion
valid_from: 2026-04-20
valid_until: null
deprecated_by: null
depends_on: [] # synthesis notes: atomic note slugs
sources:
- ../../references/source-file.md
related:
- "[[other-note]]"
- "[[other-kb:cross-kb-note]]"
---
Body with [[wikilinks]] and inline citations
([Author 2024](../../references/author-paper-2024.md)).
## Key Takeaways
- Bullet points for quick scanningYou can extend the base note format with richer templates for specific domains. For example, an incident/post-mortem note in any domain might use sections like:
## Summary
## Artifacts β identifiers, links, evidence
## Sequence of Events
## Root Cause
## The Fix
## Review History β prior audits / reviews and what they found
## Classification β category, severity, taxonomy IDs
## Similar Cases β cross-links to related notes
## Reproduction β how to verify or reproduce
## Key Takeaways
Add your own templates per KB as needed.
Note Reference File Original Source
ββββββββββββββββ ββββββββββββββββββββ ββββββββββββββββ
β Claims X ββββββββΆβ # Title βββββββββΆβ https://... β
β [cite](ref) β β Source: URL β β The actual β
β β β Source-Type: β β web page β
β β β primary β β β
ββββββββββββββββ β ## Key Content β ββββββββββββββββ
ββββββββββββββββββββ
Notes cite local reference files, not external URLs directly. Reference files store structured summaries with the original URL and a source type classification. This keeps the KB self-contained, offline-verifiable, and quality-traceable.
python3 .kb/build-dashboard.py
open publish/dashboard.htmlInteractive HTML dashboard with 4 tabs:
- Overview: KB cards, topic treemap, type distribution, notes over time
- Knowledge Graph: D3 force-directed link graph, coverage radar, bridge concepts, tag co-occurrence network
- Research: open research gaps (with severity coloring), timeline, depth heatmap
- Quality: gap burden chart, retrieval heatmap
All via python3 .kb/kb-index.py <command> [--kb <name>]:
| Command | Purpose |
|---|---|
build [--incremental] |
Build per-KB + unified indices |
search "query" [--multi "alt1" "alt2"] |
Multi-query hybrid search with RRF fusion |
quick "query" |
Instant title/slug/tag match |
| Command | Purpose |
|---|---|
lint [slug] |
Validate frontmatter, wikilinks, citations, tags |
patterns |
Detect recurring topic patterns, flag unsynthesized ones |
contradictions-scan |
Find conflicting amounts, dates, classifications |
gaps [topics|research|suggestions|all] |
Topic gaps, research gaps, ranked suggestions |
| Command | Purpose |
|---|---|
graph [orphans|components|bridges|neighbors] |
Link graph analysis |
map |
Topic map with coverage stats and link density |
explore <slug> [steps] |
Suggested reading path |
backlink [slug] |
Add missing reverse wikilinks (including cross-KB) |
| Command | Purpose |
|---|---|
eval [retrieval|generation|all] |
Retrieval metrics (Recall@5, MRR, nDCG@5) |
feedback [summary|log] |
Search quality feedback loop |
stats |
Index statistics with type distribution |
The KB exposes a read-only MCP server for external tools:
uv run --directory .kb python mcp_server.pyββββββββββββββββ ββββββββββββββββ ββββββββββββββββ
β Claude Code β β Cursor β β Claude β
β (any project)β β β β Desktop β
ββββββββ¬ββββββββ ββββββββ¬ββββββββ ββββββββ¬ββββββββ
β β β
ββββββββββββββ¬βββββββββββββββββββββββββββββ
β MCP (stdio)
βββββββ΄ββββββββββββββββββββββββββββββ
β SynapseNotes MCP Server β
β β
β kb_list kb_search kb_quick β
β kb_read kb_map kb_explore β
β kb_gaps kb_stats kb_coverage β
β β
β All tools accept optional `kb` β
β parameter. Private KBs excluded. β
ββββββββββββββββββββββββββββββββββββββ
Configure in Claude Code (~/.claude/settings.json):
{
"mcpServers": {
"knowledge-base": {
"command": "uv",
"args": ["run", "--directory", "/path/to/KnowledgeBase/.kb", "python", "mcp_server.py"]
}
}
}Requirements: Python 3.9+ (for kb-index.py), Python 3.12+ with uv (for MCP server), Claude Code.
# Clone
git clone <repo-url> && cd SynapseNotes
# Install Python deps
pip3 install pyyaml scikit-learn numpy markdown
# Initialize
cp kbs.example.yaml kbs.yaml
cp tests/eval_data.example.json tests/eval_data.json
cp .kb/taxonomy.seed.yaml .kb/taxonomy.yaml
mkdir -p kbs/general kbs/personal
python3 .kb/kb-index.py build
# (Optional) MCP server
cd .kb && uv sync && cd ..
# Start using
# /kb-init my-domain
# /kb-research "topic of interest" --depth deep
# /kb-search "your query"- Atomic notes β one concept per file, linked via wikilinks. Target 400-700 words.
- Epistemic honesty β every note tracks confidence (verified β opinion). Sources classified by reliability.
- Multi-KB separation β private, general, and domain KBs with smart routing.
- Active quality management β pattern detection, contradiction scanning, gap suggestions. The KB analyzes itself.
- Measurable retrieval β evaluation harness with golden queries. Infrastructure changes are regression-tested.
- Local-first citations β reference files bridge notes to the web. Self-contained and offline-verifiable.
- Tool-accessible β MCP server exposes all read operations to any LLM tool.
- Obsidian-compatible β standard markdown with YAML frontmatter and
[[wikilinks]].
Tracked (machinery): Gitignored (per-user / content):
.kb/kb-index.py kbs.yaml
.kb/build-report.py kbs/*/
.kb/build-dashboard.py references/
.kb/mcp_server.py publish/
.kb/config.yaml .kb/taxonomy.yaml
.kb/pyproject.toml .kb/log.md
.claude/skills/ .kb/index/
tests/*.py tests/eval_data.json
kbs.example.yaml tests/*_results.json
tests/eval_data.example.json
CLAUDE.md
The system is reproducible; the content is yours.