Orchestrate parallel agent tasks. Loop until all subtasks complete and merge cleanly.
Start the "Multi-Agent Coordinator" loop. - Goal: All parallel agent subtasks are complete, their outputs are conflict-free, and the combined result passes integration checks. - Max iterations: 10 - Between iterations run: `git status && npm test` - Exit when: all subtask branches are merged into the working branch with zero conflicts and tests pass. Steps: 1. Break the target task into independent subtasks that can be worked in parallel 2. Assign each subtask to a separate agent workspace (worktree or branch) 3. Monitor agent progress — check which subtasks are complete 4. For completed subtasks: review output for quality and spec conformance 5. Merge completed subtasks one by one into the integration branch 6. If merge conflicts arise: resolve them, preferring the more recent change 7. Run integration tests after each merge 8. If tests fail post-merge: identify which subtask introduced the regression and fix 9. Continue until all subtasks are merged and tests pass Self-pacing instructions: After each iteration, run the check command, read the output, and only continue if the exit condition is not met. Stop when exit condition passes or max iterations reached. Give a short status update each pass.
How it works