| name | orchestrator |
| description | Multi-phase workflow orchestration pattern for main agents. Enables structured planning, delegation to sub-agents, parallel execution, and result aggregation. |
Orchestrator Skill
You are operating with orchestration capabilities. Follow this 4-phase workflow pattern to break down complex tasks and delegate to specialized sub-agents.
Phase 1: Planning
Before starting any work, analyze the task and create a structured plan:
<orchestration_plan>
<task_summary>Brief description of the overall task</task_summary>
<work_items>
<item id="1" parallel_group="A">
<description>What needs to be done</description>
<sub_agent>sub-agent-name</sub_agent>
<dependencies>none</dependencies>
<inputs>What this sub-agent needs</inputs>
<expected_output>What this sub-agent will produce</expected_output>
</item>
<item id="2" parallel_group="A">
<description>Another independent task</description>
<sub_agent>another-sub-agent</sub_agent>
<dependencies>none</dependencies>
<inputs>...</inputs>
<expected_output>...</expected_output>
</item>
<item id="3" parallel_group="B">
<description>Task that depends on items 1 and 2</description>
<sub_agent>yet-another-sub-agent</sub_agent>
<dependencies>1, 2</dependencies>
<inputs>Outputs from items 1 and 2</inputs>
<expected_output>...</expected_output>
</item>
</work_items>
<execution_order>
<parallel_group name="A" items="1, 2"/>
<parallel_group name="B" items="3" after="A"/>
</execution_order>
</orchestration_plan>
Phase 2: Delegation
Execute your plan by invoking sub-agents:
Task(subagent_type="sub-agent-name", prompt="
<task>
[Specific task description from work item]
</task>
<context>
[Any relevant context or outputs from previous items]
</context>
<expected_deliverables>
[What this sub-agent should produce]
</expected_deliverables>
")
Phase 3: Execution Monitoring
As sub-agents complete their work:
Phase 4: Aggregation
After all sub-agents complete, synthesize results:
Parallelization Guidelines
MUST run sequentially:
- Tasks where output feeds into another task's input
- File modifications to the same files
- Tasks with explicit dependencies
Error Handling
- Assess Impact: Determine if dependent items can proceed
- Retry Option: Consider retrying with clarified instructions
- Fallback: If sub-agent unavailable, attempt the work directly
- Escalate: If critical failure, report to user with details