Choose execution shape.
This is mandatory. Do not start editing product code until the execution shape is chosen and recorded in the implementation attempt.
Do not use "the user did not explicitly ask for subagents this turn" as a reason to keep work local. The explicit request is the use of implement-slice; decide based on the slice contract, execution fit, risk, parallel ownership, and platform availability.
Use the prepared Parallel Work Chunks first:
- If the slice defines parallel chunks, spawn one implementation subagent per
agent or suitable either chunk when the platform supports subagents.
- Do not spawn subagents for chunks marked
human unless the user asks to use the agent fallback.
- For chunks marked
hybrid, do the agent-fit context gathering or mechanical work, then pause for the human decision before finalizing that chunk unless the contract says the agent fallback is acceptable.
- If a chunk is marked
human, pause before implementation and present the human handoff, reason, timebox, and agent fallback. Ask whether the user wants to do it by hand or have the agent continue with the fallback.
- Keep chunks as written unless a chunk has become unsafe, stale, overlapping, or impossible. If so, record the reason before adjusting execution shape.
- Assign each subagent the chunk's concrete output, owned files/modules/responsibilities, dependencies, post-implementation test focus, and review focus.
- Tell each subagent to skip new test coverage unless a minimal test/probe is required to unblock implementation.
- Keep one immediate integration or critical-path task local when useful, but do not duplicate a chunk already owned by a subagent.
If the slice has no usable chunks, default to subagents for non-trivial slices when the platform supports them. A slice is non-trivial if it touches multiple modules, has distinct implementation and test surfaces, requires both codebase discovery and code edits, or has enough contract detail that separate ownership areas can be defined.
Use one to three implementation subagents when any disjoint ownership split is available. If more than three chunks would be needed, stop and ask to re-prepare the slice or merge chunks before implementation.
Keep work local only when one of these is true:
- the slice is genuinely tiny
- all changes are tightly coupled in one file or one small function
- all remaining chunks are marked
human and the user chooses to do them by hand
- the slice contract explicitly says
Parallel Work Chunks: serial/local-only and the reason still holds
- subagents are unavailable in the current environment
- repository instructions explicitly prohibit subagent dispatch
- the next action is an urgent blocker that must be done before any useful parallel work exists
If keeping work local or pausing for human work, write the reason into Implementation Notes before editing product code.
If the platform rejects spawning even though the execution shape calls for subagents, continue locally only after recording that platform blocker in the implementation notes and final response.
When delegating:
- Assign disjoint ownership with explicit files, modules, or responsibilities.
- Tell each subagent it is not alone in the codebase.
- Tell each subagent not to revert edits made by others.
- Require each subagent to list changed files and any lightweight verification performed.
- Require each subagent to identify the tests that
implement-tests should add or update for its chunk.
- Require each subagent to report whether its chunk contract was completed, partially completed, or blocked.
- Keep one immediate critical-path task local instead of blocking entirely on subagents.
- After each subagent result is captured and no further input is needed, close that subagent.
wait_agent does not close it automatically.