second-brain

Installation
SKILL.md

Second Brain

Maintain a source-grounded OKF v0.2 wiki, following Karpathy's LLM Wiki proposal. The agent owns synthesis; the stdlib-only Python 3.10+ CLI handles file, history and index operations. Markdown is authoritative; index.db is rebuildable FTS5.

Scope first

  • Explicit user scope wins. Project knowledge belongs in the project's initialized knowledge/; personal and cross-project knowledge belongs in SECOND_BRAIN_DIR or ~/second-brain/. If a requested project bundle is missing, offer init; never silently write globally.
  • Run from the project root. Every project command puts --vault knowledge before the subcommand. Keep follow-up commands and bundle-relative --related / --supersedes paths in the same bundle.
  • Read schema.md, the root index and relevant folder indexes. Preserve owner rules, existing paths and human-curated text outside generated index blocks. Initialization does not authorize reorganizing existing files.
  • Resolve bundled paths from this skill's directory. Use uv run <skill-dir>/scripts/sb.py --help and subcommand help when arguments are unclear.

Recall

Search project knowledge first unless the owner chose global only; search global if no relevant result. Use rg when an index or match is unavailable. Read the best 1–3 matches and follow their evidence, preferring relevant maintained pages over an event trail.

uv run <skill-dir>/scripts/sb.py --vault knowledge search "<terms>" -n 5
uv run <skill-dir>/scripts/sb.py search "<terms>" -n 5
Installs
21
Repository
legout/skills
First Seen
Sep 24, 2026