Search Second Brain
Local-first retrieval over the user's Obsidian vault at ~/Documentos/second-brain
using Ollama (qwen2.5:7b). No data leaves the machine.
When to use
Invoke this skill whenever the user wants to read / search / query / recall anything from their second brain or notes.
How to search
Run the search script with the user's question as the argument:
python3 ~/.claude/skills/search-second-brain/search.py "<the user's question>"
The script will:
- Ensure
ollama serveis running (starts it detached if needed). - Verify the model is present.
- Retrieve the most relevant notes (keyword scoring over the vault).
- Ask
qwen2.5:7bto answer using only those notes, with sources.
Relay the answer to the user, and mention which notes were retrieved.
Node CRUD
Each Claude turn already auto-creates a node via the Stop hook (see
nodes/ and nodes/_log.md in the vault). For manual operations:
SB=~/.claude/skills/search-second-brain/crud_node.py
python3 $SB create --title "Title" --body "Text" --tags a,b --links Other-Note
python3 $SB read --name <node-stem-or-substring>
python3 $SB update --name <node> --append "more text"
python3 $SB delete --name <node>
python3 $SB list
Graph-first
This vault is a knowledge graph. Keep it connected:
Auto-captured nodes are linked into the graph automatically (Stop hook links each node to its top relevant notes + the previous node).
When you create or curate notes, add a
## Linkssection with[[wikilinks]].Repair orphans anytime:
python3 ~/.claude/skills/search-second-brain/link_orphans.py # link only orphans python3 ~/.claude/skills/search-second-brain/link_orphans.py --all # re-link everything
Configuration (env overrides)
SECOND_BRAIN_VAULT— vault path (default~/Documentos/second-brain)SECOND_BRAIN_MODEL— Ollama model (defaultqwen2.5:7b)OLLAMA_HOST— Ollama API (defaulthttp://localhost:11434)