From dossier
Bug → §V protocol. On bug report or failed test, trace root cause, decide whether a new §V invariant prevents recurrence, append §B row + optional §V row + regression test. One commit. Resumable. Invoke when the user says "ds:backprop", "bug: <description>", "backprop B<N>", "root-cause this", "add invariant for <X>", or auto-trigger from ds:build on test failure.
How this skill is triggered — by the user, by Claude, or both
Slash command
/dossier:backprop <B-id> | <bug-description> | --resume<B-id> | <bug-description> | --resumeThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Six steps. Append-only on §B + §V. Resumable.
Six steps. Append-only on §B + §V. Resumable.
<B-id> (e.g. B5): existing bug row, resume / amend.<bug-description> free text: new bug, scaffold §B row from it.--resume: explicit override of auto-detected resume point.Per ADAPTERS.md. Note HAS_CAVEMEM (recurrence research benefits).
Per ds:status step 1. Refuse if none.
Write <dir>/.ds-lock with skill: "ds:backprop", target: "B<N-or-pending>".
Read §S grep ds:backprop <target>:
| Last event | Resume point |
|---|---|
| (none) | full run from step 4 |
START | step 4 (re-scope) |
test=<sha> | step 6 |
§B=B<N> | step 7 (invariant decision) |
§V=V<N> | step 8 (fix) |
fix=<sha> | step 9 (close) |
DONE | exit |
Append §S as its own paragraph (blank line before AND after — per FORMAT.md §11; applies to every §S append in this skill):
<YYYY-MM-DD HH:MM> ds:backprop <B-or-pending> START
Define:
If root cause is fuzzy or class-of-bug research needed: spawn dossier-scout subagent with mission "research : where does this class manifest? Prior occurrences? Test gaps?". If HAS_CAVEMEM=1, also query mcp__cavemem__search for prior observations of same class.
Write test that reproduces the bug. Run → must FAIL (RED). If it passes, the bug isn't characterized correctly — revisit step 4.
Commit:
test(<scope>): repro <bug-label>
Refs §B B<N>
Append §S:
<YYYY-MM-DD HH:MM> ds:backprop B<N> test=<sha>
If bug is non-testable (docs drift, infra config, etc.): skip test commit. Note in §B invariant added = — (non-testable).
Atomic write DOSSIER.md w/ new §B row:
| B<N> | <bug-label> | <root-cause> | <pending> | <test-sha-or-—> |
Append §S:
<YYYY-MM-DD HH:MM> ds:backprop B<N> §B=B<N>
Question: would a new §V invariant catch recurrence?
| Recurrence | Class | Decision |
|---|---|---|
| high | systemic | YES — append §V row |
| mid | local | maybe — operator call |
| low | one-off | NO — patch-only |
If YES: append §V row pointing at the test from step 5 (or new check):
| V<N> | <invariant claim> | <test-name> |
Update §B invariant added column to V<N>. Atomic write.
Append §S:
<YYYY-MM-DD HH:MM> ds:backprop B<N> §V=V<N>
If NO: §B invariant added stays —. Note in §S §V=skipped:one-off.
Implement fix. Run regression test → GREEN. Run full test suite (or scoped) → no regressions.
Commit:
fix(<scope>): <imperative summary>
<body if non-obvious>
Refs §B B<N>
Append §S:
<YYYY-MM-DD HH:MM> ds:backprop B<N> fix=<sha>
Update §B fix cite column to <sha>. Atomic write.
Append §S:
<YYYY-MM-DD HH:MM> ds:backprop B<N> DONE
Release lock. Regen INDEX (B count change).
ds:backprop B<N> → fixed
test=<sha>, fix=<sha>
§V<N> added [or skipped: <reason>]
If ds:build test fails: invoke ds:backprop with bug-description = test failure message. Then resume ds:build after backprop closes.
npx claudepluginhub raisedadead/claude-code-plugins --plugin dossierGuides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.