From superpowers-cccg
Executes plans by dispatching fresh subagent per task with two-stage review (spec then quality). Use when: executing implementation plans in current session with independent tasks. Keywords: subagent, task execution, fresh context, iterative development
How this skill is triggered — by the user, by Claude, or both
Slash command
/superpowers-cccg:developing-with-subagentsThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
- [Overview](#overview)
Execute plan by routing each task to the appropriate external model (Codex/Gemini/Cursor based on domain), with spec compliance review first (Opus), then Opus code quality review on every code-changing path.
Core principle: Route to external model per task + Opus review (spec then quality) = high quality, fast iteration. Claude orchestrates but never implements.
Follow skills/shared/protocol-threshold.md. The hook injects CP reminders automatically.
digraph when_to_use {
"Have implementation plan?" [shape=diamond];
"Tasks mostly independent?" [shape=diamond];
"Stay in this session?" [shape=diamond];
"developing-with-subagents" [shape=box];
"executing-plans" [shape=box];
"Manual execution or brainstorm first" [shape=box];
"Have implementation plan?" -> "Tasks mostly independent?" [label="yes"];
"Have implementation plan?" -> "Manual execution or brainstorm first" [label="no"];
"Tasks mostly independent?" -> "Stay in this session?" [label="yes"];
"Tasks mostly independent?" -> "Manual execution or brainstorm first" [label="no - tightly coupled"];
"Stay in this session?" -> "developing-with-subagents" [label="yes"];
"Stay in this session?" -> "executing-plans" [label="no - parallel session"];
}
vs. Executing Plans (parallel session):
Copy this checklist template to track overall progress:
Plan Execution Progress:
- [ ] Plan read and all tasks extracted
- [ ] TodoWrite created with all tasks
Per-Task Checklist (copy for each):
Task N: [description]
- [ ] Checkpoint 1 (Task Analysis) applied
- [ ] 【CP1 Assessment】 output (standalone message)
- [ ] Implementer subagent dispatched
- [ ] Questions answered (if any)
- [ ] Implementation complete
- [ ] Checkpoint 3 (Quality Gate) applied
- [ ] Spec reviewer: ✅ compliant
- [ ] Opus review: ✅ approved
- [ ] Task marked complete
Final Steps:
- [ ] All tasks complete
- [ ] Final code reviewer dispatched
- [ ] finishing-development-branches invoked
digraph process {
rankdir=TB;
subgraph cluster_per_task {
label="Per Task";
"Route to external model (Codex/Gemini/Cursor per routing)" [shape=box];
"External model asks questions?" [shape=diamond];
"Answer questions, provide context" [shape=box];
"External model implements, tests, commits" [shape=box];
"Dispatch spec reviewer subagent (./spec-reviewer-prompt.md)" [shape=box];
"Spec reviewer subagent confirms code matches spec?" [shape=diamond];
"External model fixes spec gaps" [shape=box];
"Review chain (./code-quality-reviewer-prompt.md)" [shape=box];
"Opus final arbiter approves?" [shape=diamond];
"External model fixes quality issues (max 3 loops)" [shape=box];
"Mark task complete in TodoWrite" [shape=box];
}
"Read plan, extract all tasks with full text, note context, create TodoWrite" [shape=box];
"More tasks remain?" [shape=diamond];
"Dispatch final code reviewer subagent for entire implementation" [shape=box];
"Use superpowers:finishing-development-branches" [shape=box style=filled fillcolor=lightgreen];
"Read plan, extract all tasks with full text, note context, create TodoWrite" -> "Route to external model (Codex/Gemini/Cursor per routing)";
"Route to external model (Codex/Gemini/Cursor per routing)" -> "External model asks questions?";
"External model asks questions?" -> "Answer questions, provide context" [label="yes"];
"Answer questions, provide context" -> "Route to external model (Codex/Gemini/Cursor per routing)";
"External model asks questions?" -> "External model implements, tests, commits" [label="no"];
"External model implements, tests, commits" -> "Dispatch spec reviewer subagent (./spec-reviewer-prompt.md)";
"Dispatch spec reviewer subagent (./spec-reviewer-prompt.md)" -> "Spec reviewer subagent confirms code matches spec?";
"Spec reviewer subagent confirms code matches spec?" -> "External model fixes spec gaps" [label="no"];
"External model fixes spec gaps" -> "Dispatch spec reviewer subagent (./spec-reviewer-prompt.md)" [label="re-review"];
"Spec reviewer subagent confirms code matches spec?" -> "Review chain (./code-quality-reviewer-prompt.md)" [label="yes"];
"Review chain (./code-quality-reviewer-prompt.md)" -> "Opus final arbiter approves?";
"Opus final arbiter approves?" -> "External model fixes quality issues (max 3 loops)" [label="no"];
"External model fixes quality issues (max 3 loops)" -> "Review chain (./code-quality-reviewer-prompt.md)" [label="re-review"];
"Opus final arbiter approves?" -> "Mark task complete in TodoWrite" [label="yes"];
"Mark task complete in TodoWrite" -> "More tasks remain?";
"More tasks remain?" -> "Route to external model (Codex/Gemini/Cursor per routing)" [label="yes"];
"More tasks remain?" -> "Dispatch final code reviewer subagent for entire implementation" [label="no"];
"Dispatch final code reviewer subagent for entire implementation" -> "Use superpowers:finishing-development-branches";
}
./implementer-prompt.md - Dispatch implementer subagent (legacy template — prefer routing to external models via MCP)./spec-reviewer-prompt.md - Dispatch spec compliance reviewer subagent./code-quality-reviewer-prompt.md - Dispatch Opus quality reviewRoute implementation to external models. Claude orchestrates only.
| Role | Model | Selection Rule |
|---|---|---|
| Backend implementation | Codex MCP (mcp__codex__codex) | CODEX routing |
| Frontend implementation | Gemini MCP (mcp__gemini__gemini) | GEMINI routing |
| DevOps implementation | Cursor MCP (mcp__cursor__cursor) | CURSOR routing |
| Spec Reviewer | Opus (default) | Always Opus |
| Quality Reviewer | Opus | Always Opus for code-changing paths |
| Exploration | model: haiku | Flexible |
Apply checkpoint logic from coordinating-multi-model-work/checkpoints.md at these stages:
► CP1 (Task Analysis): Before dispatching implementer, apply coordinating-multi-model-work/checkpoints.md.
► CP2 (Mid-Review): During execution, apply coordinating-multi-model-work/checkpoints.md if triggered.
► CP3 (Quality Gate): After implementation, invoke spec reviewer, then Opus quality review per coordinating-multi-model-work/review-chain.md.
You: I'm using Subagent-Driven Development to execute this plan.
[Read plan file once: docs/plans/feature-plan.md]
[Extract all 5 tasks with full text and context]
[Create TodoWrite with all tasks]
Task 1: Hook installation script
[Get Task 1 text and context (already extracted)]
[Dispatch implementation subagent with full task text + context]
Implementer: "Before I begin - should the hook be installed at user or system level?"
You: "User level (~/.config/superpowers/hooks/)"
Implementer: "Got it. Implementing now..."
[Later] Implementer:
- Implemented install-hook command
- Added tests, 5/5 passing
- Self-review: Found I missed --force flag, added it
- Committed
[Dispatch spec compliance reviewer]
Spec reviewer: ✅ Spec compliant - all requirements met, nothing extra
[Dispatch Opus reviewer with diff + task context]
Opus: APPROVE — Good test coverage, clean implementation. No issues found.
[Mark Task 1 complete]
Task 2: Recovery modes
[Get Task 2 text and context (already extracted)]
[Dispatch implementation subagent with full task text + context]
Implementer: [No questions, proceeds]
Implementer:
- Added verify/repair modes
- 8/8 tests passing
- Self-review: All good
- Committed
[Dispatch spec compliance reviewer]
Spec reviewer: ❌ Issues:
- Missing: Progress reporting (spec says "report every 100 items")
- Extra: Added --json flag (not requested)
[Implementer fixes issues]
Implementer: Removed --json flag, added progress reporting
[Spec reviewer reviews again]
Spec reviewer: ✅ Spec compliant now
[Dispatch Opus reviewer]
Opus: Issues (Important): Magic number (100)
[Implementer fixes]
Implementer: Extracted PROGRESS_INTERVAL constant
[Re-submit Opus reviewer]
Opus: APPROVE
[Mark Task 2 complete]
...
[After all tasks]
[Dispatch final code-reviewer]
Final reviewer: All requirements met, ready to merge
Done!
vs. Manual execution:
vs. Executing Plans:
Efficiency gains:
Quality gates:
coordinating-multi-model-work/review-chain.mdCost:
Never:
If subagent asks questions:
If reviewer finds issues:
If subagent fails task:
Required workflow skills:
Subagents should use:
Alternative workflow:
See skills/shared/multi-model-integration-section.md for routing, invocation, and fallback rules.
npx claudepluginhub sitien173/superpowers-cccgCreates structured, bite-sized implementation plans from specs or requirements before writing code. Useful for breaking down multi-step tasks into testable steps with file structure and task boundaries.