From knowledge-base
Consult the user's Obsidian knowledge base for documented gotchas and patterns BEFORE attempting any fix, migration, deploy, or Jira/WFR subtask — even when the user did not explicitly ask. Use this skill whenever the prompt involves database migrations (Drizzle, Postgres schema changes), authentication (JWT, cookies, session middleware, auth-service), deploy / CI errors (ALB health checks, ECS crashloops, exit code 143, 502s, P1001 db-unreachable), networking (nginx, CORS preflight, Set-Cookie, cross-origin), Docker / docker-compose / volumes, cron or background workers, Jira / WFR subtask kickoffs, or ANY pasted error message or stack trace. Guessing a fix from conversation memory when these triggers apply is exactly the failure mode this skill exists to prevent. Always announces "KB hit" or "KB checked — no matches" — the no-matches announcement is the forcing function proving the skill ran.
How this skill is triggered — by the user, by Claude, or both
Slash command
/knowledge-base:knowledge-lookupThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You are consulting the user's Obsidian Knowledge Base before solving a problem. The goal is to replace "guessing from memory" with "research from the KB." If the KB has an entry, use it. If it doesn't, research the real code / docs / error — don't fall back to half-remembered fixes.
You are consulting the user's Obsidian Knowledge Base before solving a problem. The goal is to replace "guessing from memory" with "research from the KB." If the KB has an entry, use it. If it doesn't, research the real code / docs / error — don't fall back to half-remembered fixes.
Read the single index file:
~/Documents/workspace/obsidian-vault/claude-code/Resources/MOC-Knowledge-Base.md
This is cheap — one line per entry. If the path doesn't exist, announce KB unavailable — vault not mounted at expected path and stop (do not halt the user's task; just proceed without the KB).
Determine three things:
Current project slug, resolved in this order:
project_slug frontmatter in the repo's CLAUDE.md (if present)/Users/harshagarwal/Documents/workspace/c360 → c360)cross onlyTech area — inferred from the task description, files being edited, and any error text. Examples: drizzle, nginx, auth, deploy, migration, cookie, cors, docker, react-router, asana, jira.
Keywords — specific strings to match on. Pull them from:
backend/drizzle/)From the index lines, pick the ones where:
<scope> is cross OR matches the current project slug, AND<keywords> or <hook> text contains any of the identified tech-area words or error keywordsCollect the wikilinks from matching lines. Read each matching full doc.
For reactive lookups (an error / test failure / unexpected behavior has surfaced), additionally grep:
grep -rn "<distinctive error snippet>" \
~/Documents/workspace/obsidian-vault/claude-code/Resources/gotchas/ \
~/Documents/workspace/obsidian-vault/claude-code/Resources/patterns/ \
~/Documents/workspace/obsidian-vault/claude-code/Projects/ 2>/dev/null
Pick a distinctive phrase from the error message, not a generic word. Read any matches.
Report to the user in 1-3 bullets.
If matches found:
KB hit:
- [[Drizzle migration `when` timestamp]] — applies because we're adding a new migration file. Action: before picking a `when` value, check the journal for max existing `when`.
If no matches:
KB checked (index loaded, scope: c360 + cross, keywords: migration drizzle postgres). No matches.
The "no matches" announcement is never optional. It is the forcing function that proves the skill actually ran. If you skip this announcement, you are violating the skill contract.
When KB has no relevant entry, you MUST research the actual code / docs / error before proposing a fix. This means:
You may NOT fall back to "I think it's probably X" from conversation memory. That is exactly the failure mode this skill exists to prevent.
If the MOC file doesn't exist or has no entries, still announce:
KB checked — MOC exists but has no entries in scope <scope>. Researching from source.
Then proceed with the research-before-guess rule from Step 6.
systematic-debugging skill — if you're debugging, use both: lookup first, then systematic-debugging for the research phase.knowledge-save — lookup consumes the KB, save writes to it. They never run concurrently in the same step; lookup at task start, save at task end.The MOC index is the only file always read. Full docs are only read on match. Target: total tokens from this skill ≤ 5k on a typical task. If you find yourself reading more than 3 full docs, stop and ask yourself whether they're all actually relevant.
Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub harsh1210/claude-code-knowledge-base --plugin knowledge-base