Forge Obsidian Brain
/install forge-obsidian-brain
ForgeObsidianBrain
Analytics and capture layer for an AI's Obsidian vault. Auto-discovers vaults, manages note CRUD operations, captures fleeting thoughts, resurfaces forgotten knowledge, with fuzzy matching, regex patterns, and case-insensitive search.
Security Note: See SECURITY.md for full security model. This skill operates entirely locally with no network access.
Installation
# Clone or copy to your OpenClaw skills folder
cp -r skills/forge-obsidian-brain ~/.openclaw/workspace/skills/
# Make executable
chmod +x ~/.openclaw/workspace/skills/forge-obsidian-brain/scripts/brain.js
# Set up alias (optional)
alias brain="node ~/.openclaw/workspace/skills/forge-obsidian-brain/scripts/brain.js"
Configuration
Set the default vault path via environment variable:
export OBSIDIAN_VAULT="$HOME/obsidian-vault"
Or specify --vault \x3Cpath> for any command.
The skill auto-discovers vaults by:
- Checking
OBSIDIAN_VAULTenvironment variable - Reading Obsidian's config (
~/.config/obsidian/obsidian.json) - Falling back to
~/obsidian-vault
Commands
Core Commands
| Command | Description |
|---|---|
discover |
Auto-detect vault location |
config |
Show Obsidian configuration |
init |
Create Brain folder structure |
sync |
Bidirectional sync with memory folder |
Note CRUD
| Command | Usage |
|---|---|
read \x3Cpath> |
Read a note |
create \x3Cpath> [content] |
Create a new note |
update \x3Cpath> [content] |
Update existing note |
delete \x3Cpath> |
Delete a note |
list [folder] |
List notes in folder |
search \x3Cquery> |
Search notes by content (case-insensitive by default) |
search \x3Cquery> --fuzzy |
Fuzzy search (typo-tolerant) |
search \x3Cquery> --regex |
Regex pattern search |
exists \x3Cpath> |
Check if note exists |
Capture Commands
Capture content to structured folders:
| Command | Description |
|---|---|
capture thought \x3Ctext> |
Quick thought → Brain/Thoughts/ |
capture research --url \x3Curl> --title \x3Ctitle> |
Research ref → Brain/Research/ |
capture conversation --source \x3Csrc> --id \x3Cid> |
Chat log → Brain/Conversations/ |
Examples:
# Fleeting thought
brain capture thought "I should refactor the auth module"
# Research capture
brain capture research \
--url "https://martinfowler.com/articles/microservices.html" \
--title "Microservices Guide" \
--text "Key points about service boundaries"
# Conversation log
brain capture conversation \
--source telegram \
--id "12345" \
--text "User asked about distributed systems"
Resurface Commands
Find relevant or neglected notes:
| Command | Description |
|---|---|
resurface topic \x3Cquery> |
Fuzzy search with relevance scoring |
resurface stale --days \x3Cn> |
Find notes untouched in N days |
Examples:
# Find notes about microservices
brain resurface topic "microservices"
# Find all notes older than 30 days
brain resurface stale --days 30 --limit 20
Options
| Flag | Description |
|---|---|
--vault \x3Cpath> |
Override vault location |
--frontmatter '\x3Cjson>' |
Add frontmatter to note |
--merge |
Merge instead of replace frontmatter |
--overwrite |
Allow overwriting existing notes |
--limit \x3Cn> |
Limit results (default: 5) |
--dry-run |
Preview sync without writing |
--days \x3Cn> |
Days threshold for stale search |
--fuzzy |
Use fuzzy matching for search |
--regex |
Use regex pattern for search |
--case-sensitive |
Force case-sensitive search |
Workflow Examples
Daily Brain Maintenance
# 1. Initialize structure (once)
brain init
# 2. Capture a thought
brain capture thought "Kubernetes selectors are just labels as queries"
# 3. Save research for later
brain capture research \
--url "https://distcc.github.io/" \
--title "Distributed Compilation"
# 4. Check for stale notes to review
brain resurface stale --days 14
# 5. Sync to memory folder
brain sync
Search and Resurface
# Case-insensitive search (new default)
brain search "OpenClaw"
# Fuzzy search - matches "opneclaw" to "openclaw"
brain search "opneclaw" --fuzzy
# Regex search
brain search "^# .* Title" --regex
# Case-sensitive search
brain search "OpenClaw" --case-sensitive
# Resurface topic with fuzzy matching
brain resurface topic distributed --limit 10
# Output:
# {
# "success": true,
# "query": "distributed",
# "totalMatches": 3,
# "shown": 3,
# "searchMode": "fuzzy",
# "results": [
# { "relativePath": "Brain/Research/...", "relevance": 5, "rank": 1, "matches": [...] },
# ...
# ]
# }
Folder Structure
After brain init, your vault gets these folders:
vault/
├── Brain/
│ ├── Thoughts/ # Quick captures
│ ├── Research/ # URL references
│ ├── Conversations/ # Chat logs
│ ├── Entities/ # Structured data
│ └── Relations/ # Connections
└── .obsidian/
└── ...
Implementation Details
- Vault Discovery: Cross-platform (Linux, macOS, Windows)
- Note Format: Markdown with YAML frontmatter
- Search: Uses grep for fast content matching
- Sync: Bidirectional between
~/.openclaw/workspace/memoryand vault Inbox - IDs: Base36 timestamps for collision-resistant filenames
Security
This skill operates entirely on the local filesystem with no network access:
- No external APIs — No network requests are made
- No data exfiltration — All data stays on your machine
- No arbitrary code execution —
execSyncis used only forgreptext search with strictly validated input - Plain source code — No obfuscation, all JavaScript is readable
See SECURITY.md for complete security documentation including data access patterns, credentials, and execution details.
Related
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install forge-obsidian-brain - 安装完成后,直接呼叫该 Skill 的名称或使用
/forge-obsidian-brain触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
Forge Obsidian Brain 是什么?
CLI tool for managing an AI's Obsidian vault with note CRUD, bidirectional sync, capture commands, and intelligent resurface. Local-only — no network access.... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 73 次。
如何安装 Forge Obsidian Brain?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install forge-obsidian-brain」即可一键安装,无需额外配置。
Forge Obsidian Brain 是免费的吗?
是的,Forge Obsidian Brain 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
Forge Obsidian Brain 支持哪些平台?
Forge Obsidian Brain 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Forge Obsidian Brain?
由 LukeAustin13(@lukeaustin13)开发并维护,当前版本 v1.0.2。