/scrum — Full SDLC sprint with adversarial audit
/scrum "<goal>" orchestrates a complete SCRUM team to deliver a multi-story sprint.
The ceremonies
1. SPRINT PLANNING
product-owner → backlog of user stories + AC
tech-lead → design + risk + sequencing for each story
scrum-master → wave plan + agent assignments
2. WAVE EXECUTION (per parallel cluster)
implementer agents (general-purpose / specialists, isolation: worktree)
→ work
verifier → runs code, captures evidence, RESULT_verifier=PASS
aspect-panel → confidence-weighted vote across 5 specialized verifiers
critic → adversarial code review
3. SPRINT REVIEW
scrum-master → DoD checklist per story; only closes on full evidence
4. SPRINT AUDIT (adversarial)
sprint-auditor → independently re-derives whether each AC was delivered
adversarial: looks for drift, scope creep, mocked tests,
DoD violations, narrow fixes, dropped ACs
5. RETROSPECTIVE
/mine-transcripts → extract corrections + patterns from sprint
/tune-agent → if any agent had ≥2 verifier failures, propose patch
retro.md → what worked, what broke, what to change next sprint
Files written per sprint
<project>/sprints/sprint-<N>/
├── stories.md (product-owner)
├── designs/<US>.md (tech-lead, one per story)
├── plan.md (scrum-master)
├── evidence/<US>/ (verifier + panel + critic outputs per story)
├── review.md (scrum-master)
├── audit.md (sprint-auditor)
└── retro.md (final)
Your protocol
Phase 0: Branch / worktree isolation (mandatory pre-step)
Before invoking product-owner, ensure the sprint has its own isolated workspace.
Step 0·0 — pick a NON-COLLIDING sprint name (mandatory). Run ls <project>/sprints/ 2>/dev/null (and check docs/plans/). If sprint-<N> for your intended integer ALREADY EXISTS, do NOT reuse it — its stories.md/audit.md/review.md are a different sprint and will contaminate your Product Owner and Sprint Auditor (they'll read the stale backlog and audit the wrong thing). Use a UNIQUE name: sprints/sprint-<slug>-<YYYY-MM-DD>/ (e.g. sprint-sota-activation-2026-05-31). The branch/worktree/tag all derive from this unique name. Then COMMIT the planning artifacts (stories.md, designs/, plan.md) immediately after the PO/tech-lead/scrum-master write them — leaving them as uncommitted working-tree files lets a later implementer git op (stash/checkout/reset) silently revert them, losing your scope and re-exposing the stale committed version. Evidence: 2026-05-31 h-uman, naming a sprint sprint-1 in a repo with sprints 1–60 derailed both the PO (wrong first draft) and the auditor (spurious FAIL on a reverted backlog); only the committed CODE survived. See ~/.claude/rules memory feedback_scrum_sprint_dir_collision.md.
Step 0a — assess concurrent activity. Run bash scripts/sprint-status.sh (or equivalent: git status --short | wc -l, git for-each-ref refs/heads/sprint-*, git worktree list).
Step 0b — choose isolation level based on what you see:
| Signal | Recommended isolation | Why |
|---|---|---|
>5 unrelated dirty files |
Worktree | A git stash wipe could lose concurrent agent work. A worktree gives you a separate working directory that the other agents can't touch. |
>1 sprint-* branch with recent commits |
Worktree | Multiple sprints in flight on the same workspace share a single index — Sprint 1 was wiped twice this way. |
>1 active worktree already |
Worktree | Mixing branch + worktree in one repo is the same risk surface as the original wiped-tree event. |
| Otherwise (calm workspace) | Branch | Lighter weight; sufficient when you control the workspace. |
Worktree isolation:
git worktree add ../human-sprint-<N> -b sprint-<N>-<slug>
cd ../human-sprint-<N>
Branch isolation:
- If
git branch --show-currentreturns asprint-<N>-*branch: continue. - Otherwise:
git checkout -b sprint-<N>-<slug>from a stable base (usuallymainor the previous sprint's tip). - If the working tree has unstaged changes that aren't the sprint's:
git stash push -m "pre-sprint-<N>"first.
Step 0c — record the choice. The sprint-master writes the chosen branch name AND the working directory (worktree path or repo path) to <project>/sprints/sprint-<N>/plan.md and surfaces it in every standup. If the branch name later changes, OR a different working directory is observed, that's a process violation — flag it.
Why this matters: Sprint 1 ran on a shared feat/* branch and was wiped twice by concurrent git reset --hard HEAD. Sprint 2b discovered that even with a dedicated branch, a concurrent agent later renamed the branch tip to point at unrelated work — only because Sprint 2b's commits stayed reachable as detached objects (and git rev-parse <sha> recovered them) did the audit trail survive. A worktree gives you a separate working directory the other agents can't touch even if they git reset the branch ref.
Phase 1: Plan
- Spawn
product-owneragent with the goal. It returnsRESULT_product-owner=READY|NEEDS_CLARIFICATION|NEEDS_DESCOPE.- If NEEDS_CLARIFICATION: surface to user, wait, retry.
- If NEEDS_DESCOPE: split goal across multiple sprints; user picks first.
- For each story (parallel where possible), spawn
tech-leadto author design + risk. - Spawn
scrum-masterwith the stories + designs to write the wave plan. The wave plan MUST cite the sprint branch name from Phase 0.
Phase 2: Execute
For each wave in plan:
- Read scrum-master's plan; identify the agents to spawn.
- Spawn parallel implementer agents (
Agenttool withisolation: worktree). Each implementer prompt MUST include:- "Commit your work to
<sprint-branch>withgit add <paths> && git commit -m \"...\"BEFORE reporting DONE. Working-tree-only DONE reports will be rejected." - Mandatory closing-line contract: Your final report MUST have this exact format, with exit codes from a FRESH subprocess (not cached state):
RESULT_implementer-<story>=DONE|PARTIAL|BLOCKED commits=<int> build-exit=<int> # from fresh `cmake --build` AFTER all edits test-exit=<int> # from fresh `./build/human_tests` AFTER all edits test-summary="<paste verbatim from test output — Results: N/M passed —" git-log-evidence="<paste of git log <sprint-base>..HEAD --oneline>" asan=CLEAN|HAS_ERRORSDONErequires: build-exit=0 AND test-exit=0 AND asan=CLEAN AND test-summary showing actual counts (not hallucinated).PARTIALis acceptable: includecompleted=<list>andremaining=<list>. Stubs asserting onlyHU_ASSERT_TRUE(1)do NOT count toward test counts.- Do NOT report DONE if exit codes are non-zero. Honest PARTIAL beats fabricated DONE.
- "Commit your work to
- After each implementer reports done:
- Verify the closing-line format first. If it lacks proper exit codes or asserts DONE with build-exit≠0, reject immediately: "exit codes missing or DONE claimed with non-zero build. Re-run fresh cmake/tests and resubmit."
- Verify the commit landed:
git log <sprint-branch> ^<sprint-base> --onelineMUST show the implementer's commit. If not, reject the DONE report and re-dispatch. - Spawn
/verifyfor that story (verifier agent runs the code) - If verifier PASS: spawn
criticimmediately for adversarial review (per-story, not batched) - If critic flags HAS_FINDINGS at HIGH/CRITICAL severity: re-open the story with the finding inline; do NOT advance to aspect-panel.
- If critic CLEAN: spawn
/aspect-panelfor orthogonal coverage - If panel returns ESCALATE: surface to user; do not auto-resolve
- Mark story DONE in TodoWrite only when commit + verifier + critic + panel all pass
Phase 3: Review
Spawn scrum-master Phase 5 (Sprint Review). It writes review.md with the DoD checklist per story.
Phase 4: Audit (mandatory — never skip)
Spawn sprint-auditor with paths to stories.md and review.md. It returns one of:
RESULT_sprint-auditor=PASS→ sprint closesRESULT_sprint-auditor=PASS_WITH_NOTES→ sprint closes; notes go to retroRESULT_sprint-auditor=FAIL→ DO NOT CLOSE. Re-open the failing stories. Re-execute.RESULT_sprint-auditor=INCONCLUSIVE→ surface to user; ask for missing access
Phase 5: Retro
- Run
/mine-transcripts --since <sprint-start>over this sprint's session window. - Read agent-tuning candidates. If any agent appears ≥2 times: recommend
/tune-agent <name>. - Write retro.md with: what worked, what broke, what changed next sprint, any tuning candidates.
Phase 6: Close
- Mark all sprint TodoWrite items completed.
- Tag the close commit immutably. Run
scripts/tag-sprint-close.sh sprint-<N>from the repo root. Annotated tags don't move under branch hijacks or push-force; the tag becomes the canonical reference for any future cherry-pick, regression-hunter, or sprint-auditor invocation that needs to resolve "where did sprint-N actually end". Sprint 2c's branch-hijacking incident is the failure mode this prevents — by the time a future agent runsgit log sprint-2b-personal-model-honesty, the branch tip may have been moved by an unrelated workstream; the tagv-sprint-2b-closecannot move silently. - Print summary to user.
Hard rules
- No story closes without verifier PASS + panel PASS/CLEAN. Hold the line even when implementer is confident.
- Audit is mandatory. Never skip Phase 4.
- Audit FAIL re-opens stories. Don't quietly accept partial deliveries.
- No scope creep without explicit PO sign-off. sprint-auditor catches this; respect it.
- Retro happens even on perfect sprints. Even green-on-everything has lessons.
- Sprint runs on a dedicated branch from planning. At Phase 1, the scrum-master MUST create or check out
sprint-<N>-<slug>(a branch or worktree dedicated to this sprint) before dispatching any implementer. Sprints MUST NOT run on a shared feature branch where other workstreams are landing concurrently. Sprint 1's wiped-tree event (concurrentgit reset --hard HEADfrom another agent) is the failure mode this rule prevents. - Implementer commits before handoff. Each implementer's last action MUST be
git add+git committo the sprint-isolated branch. A "DONE" report whose work is only in the working tree is NOT done — the next implementer'sgit resetor rebase will wipe it. The scrum-master rejects DONE reports unlessgit log <sprint-branch> ^<sprint-base>shows the implementer's commit. This is not optional, even for tiny stories. - Critic runs immediately after each story closes, not at sprint end. Batched critic-at-close is how Sprint 1 shipped a regex bug into the production publish path; per-story critic catches it before the next implementer builds on top.
Cost discipline
A typical 3-story sprint costs:
- product-owner: ~$0.30 (Sonnet, 1 invocation)
- tech-lead: 3 × ~$0.50 (Opus, 1 per story)
- implementer: 3 × ~$1.00-2.00 (sonnet/opus, varies)
- verifier: 3 × ~$0.20
- aspect-panel: 3 × ~$0.50 (5 verifiers each, sonnet)
- critic: 3 × ~$0.20
- sprint-auditor: 1 × ~$0.80 (Opus, careful read)
- mine-transcripts retro: ~$0.50
Total per sprint: ~$8-15. Verify against --max-budget-usd 20 per sprint by default.
When NOT to use /scrum
- Single-line fix (just edit it; the ceremony costs more than the work)
- Exploratory spike (use
/specfor design-first; use plain/teamfor implementation if it pans out) - No clear acceptance criteria possible (PO will refuse; surface to user first)
- Test infrastructure missing (verifier can't run; auditor will be INCONCLUSIVE)
Anti-patterns to refuse
- Closing a sprint without sprint-auditor running
- Treating audit FAIL as advisory (it is HARD)
- Skipping retro
- Letting the scrum-master write code (orchestration only)
- Letting sprint-auditor trust the team's claims (independent verification only)
- Running stories sequentially when they're independent (use waves)
- Running stories in parallel when they share state (don't)
Last line
When the sprint closes successfully:
RESULT_scrum=SPRINT_CLOSED N=<sprint-num> stories=<n>/<m> audit=PASS retro=<path>
When the sprint cannot close:
RESULT_scrum=BLOCKED reason=<audit-fail|inconclusive|user-input-needed>