| name | subagent-driven-change |
| description | Use when a scoped implementation can be delegated to an implementation subagent and then independently reviewed for spec compliance before code quality. |
Subagent-Driven Change
Preconditions
Use this workflow only when the task has a clear spec, acceptance criteria, and file ownership. Keep tightly coupled or architectural decisions in the parent session unless the user explicitly asks for delegation.
Required subagents: implementer, spec-reviewer, and code-quality-reviewer.
Fresh Context
Each subagent prompt must include the full task text, relevant spec excerpts, non-goals, acceptance criteria, file ownership, constraints, expected tests, and any command limits. Do not rely on hidden chat history or a previous subagent's memory.
Flow
- Dispatch
implementer with one bounded task and the complete context it needs.
- If
implementer returns BLOCKED or NEEDS_CONTEXT, resolve that before continuing.
- If
implementer returns DONE_WITH_CONCERNS, read the concerns before review and decide whether to fix, narrow scope, or continue.
- Dispatch
spec-reviewer with the original task, relevant spec excerpts, changed files, and implementer report.
- Fix or escalate every spec-review issue before requesting code-quality review.
- Dispatch
code-quality-reviewer only after spec review reports compliance.
- Fix Critical and Important code-quality issues before handoff, or document why a finding is intentionally deferred.
- Run the relevant tests, golden tests, and doctor/check commands required by the spec before final response.
Status Values
Implementation worker status values: DONE, DONE_WITH_CONCERNS, BLOCKED, NEEDS_CONTEXT.
Spec reviewer status values: COMPLIANT, ISSUES_FOUND, NEEDS_CONTEXT.
Code-quality reviewer status values: ACCEPTABLE, ISSUES_FOUND, NEEDS_CONTEXT.
Safety
- Do not ask subagents to commit, push, create branches, install dependencies, read secrets, contact production systems, or upload source unless the user explicitly requested that action.
- Do not accept an implementation report without reading reviewer findings.
- Do not run code-quality review before spec-compliance review passes.
- Keep generated files deterministic and lockfile-tracked.
Output
Final handoff must list what changed, tests run, contract impact, security impact, remaining risks or TODOs, and whether the spec acceptance criteria are fully met.