subagent-driven-development
Subagent-Driven Development
Use this skill after the plan is written and approved. Keep the controller session as the manager: detect the harness, extract tasks, route models, decide what to delegate, keep context narrow, review the work, verify outcomes, and close agents that are no longer needed.
Use When
- The plan already exists and is approved.
- Most tasks are bounded and can be owned by one worker at a time.
- The controller can keep integration, review, and final verification centralized.
Workflow
- Confirm the plan is approved and the workspace is safe to edit.
- Capture a routing profile before dispatching work:
- harness name or family
- whether fresh workers can be spawned
- how fresh workers are spawned, such as host subagents, task tools, external CLIs, or inline fallback
- whether model or reasoning can be set per worker
- whether browser sessions can be isolated
- whether parallel execution is safe
- Load routing references only when they matter:
- read
references/harness-routing.mdwhen the harness is unclear or model and reasoning choices materially affect cost, latency, or correctness - read
references/preferred-openai-codex-preset.mdwhen the harness iscodexoropenai-chatgptand no stronger user, repo, or org policy overrides it
- read
- Extract the task list up front: acceptance criteria, dependencies, risks, shared contracts, and likely write surfaces.
- Stay in manager posture. Delegate bounded work aggressively. Keep blocking, tightly coupled, or controller-only work local.
- Route by role and task risk:
- controller = strongest available reasoning and coding setup
- implementer = fastest setup that should still pass review for the task class
- reviewer = smallest setup that can read the diff precisely enough for the risk level
- explorer = cheapest fast read-only worker
- In Codex or OpenAI harnesses, use the host's fresh subagent mechanism for workers when it is available; do not shell out to Codex CLI from inside Codex to emulate workers. Default to
gpt-5.4for the controller,gpt-5.4-minifor most implementers,gpt-5.4-minifor targeted low-risk review,gpt-5.4for risky or full review, andgpt-5.3-codex-sparkonly as an optional shallow read-only explorer when available. - Bootstrap worker context narrowly. If the repo has a canonical entrypoint such as
AGENTS.md,CLAUDE.md,WORKFLOW.md,README.md, or a memory index, point the worker there first and add only the extra context it still needs. - Check coupling before dispatching. Merge or serialize tasks that touch the same files, APIs, migrations, selectors, browser state, schemas, or shared contracts.
- Give each implementation task one fresh worker with the exact task text, acceptance criteria, owned write scope, working directory, canonical entrypoint, necessary repo context, and model or reasoning hint when the harness supports it.
- If browser work is needed, give that worker its own isolated browser session. Never share live browser state across workers.
- Run review gates proportionally:
- controller verification is always required
- use both spec review and code-quality review for risky, user-visible, cross-cutting, shared-contract, or ambiguous changes
- use targeted review only for tiny doc-only or tightly scoped mechanical edits when the risk is truly low
- Verify each task in the controller session with the relevant tests, checks, or manual validation. Do not rely on the worker report alone.
- Record reusable learnings, then close finished agents once their output is fully reviewed and no longer needed.
- After all tasks finish, run fresh whole-branch verification and a whole-diff review when the overall change is large or cross-cutting.
Review Depth
Use the full two-stage review loop when the change affects external behavior, APIs, schemas, migrations, auth, permissions, billing, security-sensitive paths, browser flows, shared UI components, shared contracts, concurrency, caching, or performance-critical code.
Targeted review is acceptable only for clearly low-risk work such as docs, non-semantic renames, isolated fixture updates, mechanical import moves, or formatting refreshes with no behavior change.
When unsure, use the full loop.
References
references/harness-routing.mdreferences/preferred-openai-codex-preset.mdreferences/implementer-prompt.mdreferences/spec-reviewer-prompt.mdreferences/code-quality-reviewer-prompt.md
Guardrails
- Use this only when the plan is already approved and the tasks are mostly independent.
- Do not make workers read the plan file directly. Paste only the relevant task text and context.
- Do not flood workers with broad context when a canonical repo entrypoint exists.
- Do not dispatch conflicting tasks in parallel or give two workers the same write surface.
- Do not share browser sessions, refs, or mutable browser state across workers.
- Do not skip controller verification, and do not relax review depth for risky or shared-behavior changes.
- Do not trust an implementation success report without fresh verification evidence.
- Do not let workers invent acceptance criteria or silently make broad architectural decisions.
- Do not route every task to the strongest model by reflex.
- Do not claim a vendor-specific model is available unless the harness actually exposes it.
- Do not let a local preset override an explicit user choice, repo policy, org policy, or clear task-risk signal.
- Do not pretend model pinning or reasoning controls exist when the harness does not support them.
- Do not invoke Codex CLI from inside a Codex host to fake subagent dispatch. Use host subagents when available; otherwise run the same loop inline.
- If your environment cannot dispatch fresh subagents, run the same loop inline instead of pretending delegation exists.
More from mylesmcook/mcook-skills
adversarial-review
Use this skill when you need a serious code review, diff review, or implementation-plan review from independent reviewers. In Codex hosts, prefer a fresh Codex subagent for the Codex reviewer; otherwise use the Codex, Claude Code, and Gemini reviewer paths when available. Return a PASS, CONTESTED, or REJECT verdict.
13brainerd
>
10simple-code
Reduce incidental complexity in code and design. Use when shaping APIs, module boundaries, refactors, tests, naming, and architecture tradeoffs with a bias toward concrete, local, reversible solutions.
7git-it-out
Use this skill when the user explicitly wants final end-of-session closeout and no more branch or PR limbo: proper verification, proper commits, main/mainline landing, push, repo-native merge/release/deploy/publish steps, tracker updates, Entire/checkpoint handling when configured, and a concise handoff. Reach for it on prompts like 'git it out', 'get it out', 'ship this', 'I'm done', 'I'm going to bed', 'take this off my plate', 'finish the session', or 'get this into production'. Do not use it for greenfield implementation, open-ended debugging, broad refactors, or inventing a release process from scratch.
7laws-of-taste
>-
6simplify
Refine recently changed code for clarity, consistency, and maintainability without changing behavior. Use when the user explicitly asks to simplify, clean up, or lightly refactor touched code, reduce local complexity, remove redundancy, improve naming or structure, or make recent edits easier to read while preserving outputs, interfaces, tests, security, and accessibility.
6