sdd+ — Subagent-Driven Development
Wraps superpowers:subagent-driven-development. Requires superpowers to be
installed. Use tdd+ instead when tasks are tightly coupled or the plan is
small — subagent execution costs more tokens and pays off on independent,
parallelizable tasks.
Typed Dispatch Override
This project ships typed agent definitions in .claude/agents/. Where the
delegated superpowers skill instructs Task tool with general-purpose type,
instead dispatch the typed agent and pass only the per-task payload — the
role content lives in the agent definition:
- Implementation →
Agent(subagent_type="implementer", prompt=<full task text from plan + scene-setting context + working directory>)
- Spec compliance review →
Agent(subagent_type="spec-reviewer", prompt=<task requirements + implementer's report>)
- Code quality review →
Agent(subagent_type="code-reviewer", prompt=<DESCRIPTION + PLAN_OR_REQUIREMENTS + BASE_SHA + HEAD_SHA>)
If a typed agent is unavailable (definition deleted), fall back to a general-purpose
subagent using the superpowers prompt template for that role.
Procedure
Phase A: Load Plan
Load the plan from docs/plans/ or docs/superpowers/plans/ (or the path
given in arguments). If it carries a Spec: pointer, load the design it
names — superpowers 6.3.0's SDD setup reads that pointer to resolve plan
conflicts and ambiguities against the approved design
(#2086), and the design
is also the reference the spec-reviewer reviews against. If the pointer is
absent, do not infer a spec: treat a genuine conflict as ambiguity and stop
to ask.
Load active enforcement rules from session context (see session-start
output) — include them in every implementer dispatch prompt.
If the plan defines a signal stack, note each task's named gating signal:
that signal is the task's completion gate, and the implementer dispatch
prompt must say so.
If branch discipline is active (see session-start output) and you are on a
protected branch, create an isolated workspace before implementing — a
worktree (superpowers:using-git-worktrees) when the plan is multi-task or
the working tree is dirty, a plain feature branch otherwise.
Team-mode preflight. If session-start reported agent-teams: available (experimental) AND rules.workflow.team_execution is not never:
compute task independence from the plan's contract (disjoint **Files:**
lists AND no Depends on: marker either way). If ≥2 tasks are pairwise
independent: at offer, ask once — "Team mode available: tasks [N, M, …]
are independent — run them as parallel teammates? Sequential otherwise." —
and proceed per the answer; at auto, use team mode without asking. In
every other case (flag absent, never, declined, no independent pairs),
use the standard sequential dispatch below, unchanged.
Phase B: Execute (delegate to superpowers:subagent-driven-development)
- Invoke
superpowers:subagent-driven-development with the loaded plan.
- Per task, apply the Typed Dispatch Override above:
implementer → spec-reviewer → code-reviewer.
- Spec gaps or quality issues route back to a fresh implementer dispatch
with the reviewer's findings included in the payload.
- Do not pause between tasks. Stop only for BLOCKED you cannot resolve,
genuine ambiguity, or plan completion.
- Parallelism: this plan's tasks run sequentially — they share a branch
and usually files, so one implementer at a time per branch/worktree (the
wrapped skill's no-parallel rule applies within the plan). Orthogonal work
outside this plan (a different branch, disjoint files, no merge-order
dependency) may proceed concurrently in its own worktree; reviewers are
read-only and always safe to run in parallel.
- Dispatch one implementer per task — do not batch. superpowers 6.3.0
lets its controller batch small same-shape tasks into a single dispatch
(#2078). Decline that
here: the per-task dispatch is load-bearing for this overlay, not ceremony.
One dispatch = one task = one branch = one two-stage review = one merge in
dependency order. A batched dispatch collapses that chain into a single
multi-task branch, so the lead can no longer review and merge tasks
independently, a worktree-isolated implementer no longer maps onto
<plan-branch>-task-N, and one task's spec finding re-runs the whole
batch. In sequential mode every task already shares this plan's worktree,
so "batch only tasks that share a worktree" would enable batching on
nearly every run — the token saving is not worth losing per-task review
granularity. (Team mode needs no ruling: its tasks are dispatched to
separate worktrees by construction.)
Phase B-team: Team execution (when team mode is on)
- Create a team named after the plan (e.g.
sdd-<plan-slug>); the team's
shared task list mirrors the plan: one entry per plan task, with
Depends on: markers encoded as blocked-by edges so only unblocked tasks
are claimable.
- Spawn implementer teammates — at most 3, and never more than the number of
currently-unblocked independent tasks. Each is the typed
implementer
agent, worktree-isolated, joined to the team with a distinct name. Each
teammate's standing instructions: claim one unblocked task, execute it on
its own branch (<plan-branch>-task-N) off the plan branch following the
task's TDD steps exactly, push the branch, mark the task complete, then
claim the next unblocked task or go idle.
- Lead loop (you): on each task-completion notification, run the
standard two-stage review from Phase B (spec-reviewer, then code-reviewer)
against that task's branch. Route review findings back as new blocked
tasks assigned to a fresh implementer dispatch. Merge each approved task
branch into the plan branch in dependency order — one merge at a time,
re-running the suite after each merge.
- When all plan tasks are complete and merged: send each teammate a shutdown
request, delete the team, and continue to Phase C as in sequential mode.
- Turn budgets, worktree isolation, and enforcement apply to teammates
exactly as to any typed implementer dispatch (see architecture.md
"Subagent operations", including the worktree hook-coverage note).
Phase C: Wrap Up
- Confirm every plan task is committed and its checkboxes are complete.
- Report per-task status (DONE / DONE_WITH_CONCERNS) with commit SHAs.
Skill Chain
After completing sdd+, invoke /verify+ for full-suite verification — the
phase tracker accepts the sdd+ path.
Completion
- DONE — All plan tasks implemented, reviewed, and committed.
- DONE_WITH_CONCERNS — Plan complete; reviewer concerns noted for follow-up.
- BLOCKED — A task cannot proceed; details and attempted resolutions listed.
- NEEDS_CONTEXT — User input required to resolve ambiguity.
1---2name: sdd3description: Invoke AFTER plan+ is approved, as an alternative to tdd+ for plans with independent tasks. Wraps superpowers:subagent-driven-development with typed agent dispatch: fresh implementer subagent per task, then spec-reviewer and code-reviewer subagents. Executes the whole plan without pausing between tasks.4---56<!-- rig-generated -->78# sdd+ — Subagent-Driven Development910Wraps `superpowers:subagent-driven-development`. Requires superpowers to be11installed. Use `tdd+` instead when tasks are tightly coupled or the plan is12small — subagent execution costs more tokens and pays off on independent,13parallelizable tasks.1415## Typed Dispatch Override1617This project ships typed agent definitions in `.claude/agents/`. Where the18delegated superpowers skill instructs `Task tool with general-purpose type`,19instead dispatch the typed agent and pass only the per-task payload — the20role content lives in the agent definition:2122- Implementation → `Agent(subagent_type="implementer", prompt=<full task text from plan + scene-setting context + working directory>)`23- Spec compliance review → `Agent(subagent_type="spec-reviewer", prompt=<task requirements + implementer's report>)`24- Code quality review → `Agent(subagent_type="code-reviewer", prompt=<DESCRIPTION + PLAN_OR_REQUIREMENTS + BASE_SHA + HEAD_SHA>)`2526If a typed agent is unavailable (definition deleted), fall back to a general-purpose27subagent using the superpowers prompt template for that role.2829## Procedure3031### Phase A: Load Plan32331. Load the plan from `docs/plans/` or `docs/superpowers/plans/` (or the path34 given in arguments). If it carries a `Spec:` pointer, load the design it35 names — superpowers 6.3.0's SDD setup reads that pointer to resolve plan36 conflicts and ambiguities against the approved design37 ([#2086](https://github.com/obra/superpowers/issues/2086)), and the design38 is also the reference the spec-reviewer reviews against. If the pointer is39 absent, do not infer a spec: treat a genuine conflict as ambiguity and stop40 to ask.412. Load active enforcement rules from session context (see session-start42 output) — include them in every implementer dispatch prompt.433. If the plan defines a signal stack, note each task's named gating signal:44 that signal is the task's completion gate, and the implementer dispatch45 prompt must say so.464. If branch discipline is active (see session-start output) and you are on a47 protected branch, create an isolated workspace before implementing — a48 worktree (`superpowers:using-git-worktrees`) when the plan is multi-task or49 the working tree is dirty, a plain feature branch otherwise.50515. **Team-mode preflight.** If session-start reported `agent-teams: available52 (experimental)` AND `rules.workflow.team_execution` is not `never`:53 compute task independence from the plan's contract (disjoint `**Files:**`54 lists AND no `Depends on:` marker either way). If ≥2 tasks are pairwise55 independent: at `offer`, ask once — "Team mode available: tasks [N, M, …]56 are independent — run them as parallel teammates? Sequential otherwise." —57 and proceed per the answer; at `auto`, use team mode without asking. In58 every other case (flag absent, `never`, declined, no independent pairs),59 use the standard sequential dispatch below, unchanged.6061### Phase B: Execute (delegate to superpowers:subagent-driven-development)62631. Invoke `superpowers:subagent-driven-development` with the loaded plan.642. Per task, apply the Typed Dispatch Override above:65 implementer → spec-reviewer → code-reviewer.663. Spec gaps or quality issues route back to a fresh implementer dispatch67 with the reviewer's findings included in the payload.684. Do not pause between tasks. Stop only for BLOCKED you cannot resolve,69 genuine ambiguity, or plan completion.705. Parallelism: this plan's tasks run **sequentially** — they share a branch71 and usually files, so one implementer at a time per branch/worktree (the72 wrapped skill's no-parallel rule applies within the plan). Orthogonal work73 *outside* this plan (a different branch, disjoint files, no merge-order74 dependency) may proceed concurrently in its own worktree; reviewers are75 read-only and always safe to run in parallel.766. **Dispatch one implementer per task — do not batch.** superpowers 6.3.077 lets its controller batch small same-shape tasks into a single dispatch78 ([#2078](https://github.com/obra/superpowers/issues/2078)). Decline that79 here: the per-task dispatch is load-bearing for this overlay, not ceremony.80 One dispatch = one task = one branch = one two-stage review = one merge in81 dependency order. A batched dispatch collapses that chain into a single82 multi-task branch, so the lead can no longer review and merge tasks83 independently, a worktree-isolated implementer no longer maps onto84 `<plan-branch>-task-N`, and one task's spec finding re-runs the whole85 batch. In sequential mode every task already shares this plan's worktree,86 so "batch only tasks that share a worktree" would enable batching on87 nearly every run — the token saving is not worth losing per-task review88 granularity. (Team mode needs no ruling: its tasks are dispatched to89 separate worktrees by construction.)9091### Phase B-team: Team execution (when team mode is on)92931. Create a team named after the plan (e.g. `sdd-<plan-slug>`); the team's94 shared task list mirrors the plan: one entry per plan task, with95 `Depends on:` markers encoded as blocked-by edges so only unblocked tasks96 are claimable.972. Spawn implementer teammates — at most 3, and never more than the number of98 currently-unblocked independent tasks. Each is the typed `implementer`99 agent, worktree-isolated, joined to the team with a distinct name. Each100 teammate's standing instructions: claim one unblocked task, execute it on101 its own branch (`<plan-branch>-task-N`) off the plan branch following the102 task's TDD steps exactly, push the branch, mark the task complete, then103 claim the next unblocked task or go idle.1043. **Lead loop (you):** on each task-completion notification, run the105 standard two-stage review from Phase B (spec-reviewer, then code-reviewer)106 against that task's branch. Route review findings back as new blocked107 tasks assigned to a fresh implementer dispatch. Merge each approved task108 branch into the plan branch in dependency order — one merge at a time,109 re-running the suite after each merge.1104. When all plan tasks are complete and merged: send each teammate a shutdown111 request, delete the team, and continue to Phase C as in sequential mode.1125. Turn budgets, worktree isolation, and enforcement apply to teammates113 exactly as to any typed implementer dispatch (see architecture.md114 "Subagent operations", including the worktree hook-coverage note).115116### Phase C: Wrap Up1171181. Confirm every plan task is committed and its checkboxes are complete.1192. Report per-task status (DONE / DONE_WITH_CONCERNS) with commit SHAs.120121## Skill Chain122123After completing sdd+, invoke `/verify+` for full-suite verification — the124phase tracker accepts the sdd+ path.125126## Completion127128- **DONE** — All plan tasks implemented, reviewed, and committed.129- **DONE_WITH_CONCERNS** — Plan complete; reviewer concerns noted for follow-up.130- **BLOCKED** — A task cannot proceed; details and attempted resolutions listed.131- **NEEDS_CONTEXT** — User input required to resolve ambiguity.