Turn your AI's memory into a visual, browsable, editable knowledge graph.
Open Brain stores your thoughts, ideas, observations, and references in a Supabase database. AI tools like Claude, ChatGPT, and Cursor can read and write to it through MCP. But there's a gap: you can't easily browse, organize, or visually explore your own thoughts. The data lives in a database table, not a place designed for human navigation.
ObsidianBrain bridges that gap. It syncs every thought from your Open Brain database into an Obsidian vault as individual Markdown files. Each thought gets its own note with structured metadata, and topics and people become linked index notes.
The result: Obsidian becomes a local visual frontend for Open Brain, where you can browse your knowledge graph, click between connected ideas, and edit thoughts that sync back to the cloud.
In one sentence: ObsidianBrain turns your AI's memory database into a visual, browsable, editable knowledge graph on your computer.
┌──────────────────┐ pull ┌──────────────────┐ write ┌──────────────────┐
│ Supabase │ ───────────── │ ObsidianBrain │ ───────────── │ Obsidian Vault │
│ Cloud Database │ │ CLI Engine │ │ Local Markdown │
│ (PostgreSQL + │ ───────────── │ (Node.js / TS) │ ───────────── │ (Graph + Links) │
│ pgvector) │ push │ │ read │ │
└──────────────────┘ └──────────────────┘ └──────────────────┘
Three layers:
- Supabase — Your Open Brain database with thoughts, embeddings, and metadata
- ObsidianBrain CLI — The sync engine that transforms and transfers data
- Obsidian Vault — Local Markdown files with wikilinks, graph view, and canvases
|
Each thought becomes a Markdown file with YAML frontmatter (type, status, topics, people, action items, timestamps) and a colored callout banner showing its type. Every topic and person mentioned in your thoughts gets an index note that links back to all related thoughts. Click any Obsidian's graph view renders your entire thought network. Nodes are color-coded by type — blue for observations, green for ideas, orange for tasks, purple for references, gold for person notes. |
Edit thoughts in Obsidian and push changes back to Supabase. Create new notes locally and they get ingested with full embedding and metadata extraction via the Edge Function. Import Auto-generated JSON Canvas files for topic and people networks. Open them in Obsidian for visual node-and-edge diagrams. |
- Node.js v18+
- An Open Brain instance running on Supabase
- Obsidian (free)
# Clone and install
git clone https://github.com/ClintMoody/ObsidianBrain.git
cd ObsidianBrain
npm install
# Configure credentials
cp .env.example .env
# Edit .env with your Supabase URL and service role key
# Configure vault path
# Edit .obsidianbrain.yaml — set vault.path to your desired location
# Initialize and sync
npm run init # Create vault directory structure
npm run full # Pull thoughts + documents + generate linksThen open the vault folder in Obsidian.
| Command | What It Does |
|---|---|
npm run init |
Create vault directory structure, Obsidian config, color system |
npm run full |
The one you'll use most. Pull + documents + relink in one shot |
npm run pull |
Pull new/updated thoughts from Supabase |
npm run push |
Push vault edits back to Supabase |
npm run mirror |
Bidirectional sync — deletions ignored (safest) |
npm run sync |
Bidirectional sync — deletions propagate |
npm run documents |
Import external documents into the vault |
npm run relink |
Regenerate all topic/people index notes and canvases |
npm run status |
Show sync state and counts |
npm run stats |
Show Open Brain thought statistics |
Add
-- --dry-runto any sync command to preview changes without writing.
| PULL Supabase → Vault Remote is truth. Safe starting point. |
PUSH Vault → Supabase Local is truth. Send edits back. |
MIRROR Both ways Deletions ignored. Recommended default. |
SYNC Both ways Deletions propagate. Use with care. |
When both sides change the same thought, ObsidianBrain supports four strategies:
| Strategy | Behavior |
|---|---|
ask |
Pause and prompt (default) |
prefer-local |
Always keep the Obsidian version |
prefer-remote |
Always keep the Supabase version |
skip |
Skip conflicting thoughts |
Configure in .obsidianbrain.yaml under sync.conflict_strategy.
your-vault/
├── Thoughts/
│ ├── Observations/ # What you've noticed or learned
│ ├── Tasks/ # Action items and to-dos
│ ├── Ideas/ # Creative sparks and proposals
│ ├── References/ # Facts, locations, specs
│ └── PersonNotes/ # Notes about specific people
├── Topics/ # Auto-generated index notes (one per topic)
├── People/ # Auto-generated index notes (one per person)
├── Documents/ # Imported external files
├── Canvas/ # Visual network diagrams
├── _sync/ # Sync state (hidden from Obsidian)
└── .obsidian/ # Obsidian config, snippets, graph colors
Every note gets a colored callout banner showing its type. The same colors appear in the graph view, file explorer sidebar, and search results.
| Type | Color | Graph | Callout Icon |
|---|---|---|---|
| Observation | Blue | ● |
Eye |
| Task | Orange-red | ● |
Check circle |
| Idea | Green | ● |
Lightbulb |
| Reference | Purple | ● |
Bookmark |
| Person Note | Gold | ● |
User |
| Topic Index | Indigo | ● |
Hash |
| Person Index | Warm orange | ● |
User |
| Document | Slate | ● |
— |
Colors are applied automatically via a CSS snippet and graph color groups installed during npm run init.
SUPABASE_URL=https://YOUR_PROJECT_REF.supabase.co
SUPABASE_SERVICE_KEY=your-service-role-key-here
SUPABASE_INGEST_URL=https://YOUR_PROJECT_REF.supabase.co/functions/v1/ingest-thoughtsupabase:
url: "${SUPABASE_URL}"
service_key: "${SUPABASE_SERVICE_KEY}"
edge_functions:
ingest_url: "${SUPABASE_INGEST_URL}"
vault:
path: "./vault" # Where your Obsidian vault lives
documents:
source_path: "./documents" # Folder of .md/.docx files to import
sync:
mode: "mirror" # pull | push | sync | mirror
conflict_strategy: "ask" # ask | prefer-local | prefer-remote | skip
batch_size: 50
dry_run: falseEach Open Brain thought is transformed into a Markdown file:
---
id: "724bd31e-2e34-4070-bd44-ebc80856ea4d"
type: observation
status: active
topics:
- "DSP"
- "product design"
people:
- "Alice"
action_items: []
version: 1
created: 2026-03-04T05:07:34.922682+00:00
updated: 2026-03-04T05:07:34.922682+00:00
tags:
- thought
- observation
---
> [!observation] Observation
Your thought content appears here as the note body.
---
## Links
- Topics: [[DSP]], [[product design]]
- People: [[Alice]]Frontmatter makes thoughts searchable and filterable. Wikilinks connect thoughts to topic and people index notes. Callout banners provide instant visual type identification.
- Runtime: Node.js + TypeScript (via tsx)
- Database: Supabase (PostgreSQL + pgvector)
- Change detection: SHA-256 content hashing on both sides
- Sync state: JSON file in
_sync/.sync-state.json - Document conversion: Mammoth for
.docx, passthrough for.md - Metadata mapping:
type,topics,people,action_itemsare stored in the SupabasemetadataJSON column and unpacked during sync
- Don't edit files in
Topics/,People/, orCanvas/— they're regenerated on every relink - Edit thoughts freely in
Thoughts/— your changes persist through syncs - Don't delete
_sync/— it tracks sync state; removing it triggers a full re-sync - Use
--dry-runif you're unsure what a command will do - Graph view filters: Filter by
path:Thoughts/to focus on your actual thoughts
This tool is designed to work with the Open Brain Supabase schema. Your thoughts table should have:
| Column | Type | Description |
|---|---|---|
id |
uuid | Primary key |
content |
text | Thought text |
metadata |
jsonb | Contains type, topics, people, action_items |
status |
text | active, deprecated, or superseded |
version |
integer | Version number |
embedding |
vector | pgvector embedding |
created_at |
timestamptz | Creation time |
updated_at |
timestamptz | Last update time |
last_validated |
timestamptz | Last validation time |
MIT
Built to make your AI's memory yours to explore.