Skip to content
claude-mods
Menu

Mod 5 · dossier-first

Dossier-first lookup

Searches session dossiers, ADRs and plans with a scoped ripgrep and attaches a capped, untrusted-wrapped excerpt block as hidden context.

/kb <question>, the ?kb prompt prefix (!kb from -p and the SDK) and the model-callable kb_search tool run retrieval over docs/sessions, .sessions, docs/adr, docs/decisions and docs/plans in the catesworks and personal checkouts on the machine.

Results are ranked (text matches over path matches, ADRs first, recent dossiers higher), the top 5 are kept, and the block is at most 4,000 characters. Each excerpt is wrapped as untrusted data with its path, line, authority and freshness, and attached as hidden context, never as a rewrite of the prompt. Every injection writes one visible audit row.

Secret values are replaced with [redacted]; credential locations such as op:// references are kept on purpose. Pull mode is the default. Push mode, which would attach excerpts automatically, failed its gate on the measured spike and stays off.