Subagent Toolset¶
The Subagent toolset enables agents to delegate tasks to other agents in the pool.
Basic Usage¶
Available Tools¶
Subagent Tools Tools
task
Execute a task on an agent or team.
Launch a task to be executed by a specialized agent or team.
In synchronous mode (default), the task runs with streaming progress events and returns the result when complete.
In async mode, the task starts in the background and returns immediately with a task ID. The output is written to /tasks/{task_id}/output.md in the internal filesystem after the run completes.
Parameters:
| Name | Type | Required | Description |
|---|---|---|---|
agent_or_team |
string | ✓ | The agent or team to execute the task |
prompt |
string | ✓ | The task instructions for the agent or team |
description |
string | ✓ | A short (3-5 words) description of the task |
async_mode |
boolean | If True, run in background and return task ID immediately |
Category: other
Configuration Reference¶
Example Workflow¶
agents:
coordinator:
tools:
- type: subagent
system_prompt: You coordinate work between specialized agents.
researcher:
model: openai:gpt-4o
system_prompt: You research topics thoroughly.
writer:
model: openai:gpt-4o
system_prompt: You write clear documentation.
The coordinator can then delegate research to the researcher and writing to the writer.