How to Configure Delegation
๐ง Tools ยท ๐ Prompt
The delegation provider gives the agent a delegate tool for routing tasks to named specialized agents. Each delegation source contributes a set of available agents the LLM can choose from.
List and Enable Delegation Sourcesโ
za agents capabilities delegation-sources list
za agents capabilities delegation-sources configure <source-name>
Configure Provider Settingsโ
za agents capabilities delegation-sources settings
Provider Configurationโ
| Setting | Type | Default | Description |
|---|---|---|---|
enabled | bool | false | Enable the delegation provider |
verbose | bool | true | Include detailed behavioral guidance in tool description and system prompt |
include_in_prompt | bool | true | Inject delegation instructions into the system prompt |
extra_instructions | str or null | null | Append additional delegation guidance |
tool_description | str or null | null | Fully replace the default tool description |
allow_llm_selection | bool | false | Let the agent pick the target agent's LLM by name, within its allowed names |
sub_agent_approvals | ask, decline, run | ask | What a delegated agent does with a tool call that needs the user's approval, see Approvals in delegated agents |
The delegate Toolโ
When enabled and agents are available, the provider exposes a single tool:
| Tool | Description |
|---|---|
delegate | Route a task to a named specialized agent. The target agent runs in a fresh context and returns a text result. |
The LLM sees an enum of available agent names and picks the right one based on the user's request.
| Parameter | Type | Description |
|---|---|---|
agent | string (enum) | The name of the agent to delegate to |
description | string | A short (3โ5 word) label for the task |
prompt | string | A detailed, self-contained task description |
llm_configuration_name | string (optional) | Named LLM configuration for the target agent; present only when allow_llm_selection is on |
The target agent runs in isolated context: it receives the task prompt and what the user attached to the chat (documents, tags, the file open next to the Office panel), not the parent conversation. It executes with its own tools and returns a single text result. The user cannot see the delegated agent's output directly; the calling agent must relay it.
Delegation Sourcesโ
| Source | CLI name | Description |
|---|---|---|
| In-Memory Agents | in-memory-agents | Static list of named agents defined in configuration |
In-Memory Agentsโ
A static list of named agents defined directly in configuration.
za agents capabilities delegation-sources configure in-memory-agents
Configurationโ
| Setting | Type | Default | Description |
|---|---|---|---|
agents | list[DelegableAgent] | [] | The list of agents available for delegation |
Each agent entry has:
| Field | Type | Description |
|---|---|---|
agent_identifier | str | The identifier used to create the agent |
name | str | Short display name shown to the LLM in the enum |
description | str | One-line description of the agent's specialization |
bot_params | dict or null | Runtime bot_params passed to the agent factory |
allow_llm_selection | bool or null | Per-agent override of the provider's allow_llm_selection |
sub_agent_approvals | ask, decline, run or null | Per-agent setting, which can only be stricter than the provider's |
Write descriptions that include trigger phrases โ the LLM uses them to decide when to delegate:
{
"agent_delegation_provider_configuration": {
"enabled": true
},
"in_memory_delegable_agents_source_configuration": {
"enabled": true,
"agents": [
{
"agent_identifier": "research-agent",
"name": "research_agent",
"description": "Performs deep literature research with citations. Use for 'find papers about...', 'literature review', or 'what does the research say about...'"
},
{
"agent_identifier": "data-analyst",
"name": "data_analyst",
"description": "Analyzes datasets, creates charts, and computes statistics. Use for 'analyze this CSV', 'plot the trend', or 'summarize this data'."
}
]
}
}
How Delegation Worksโ
- The LLM sees the enum of available agents with their descriptions and picks the right one based on the user's request.
- Delegated agents run in isolated context: they receive the task prompt and what the user attached to the chat, not the parent conversation.
- By default a delegated agent gets no
delegatetool, anddelegateandtaskshare one budget per turn, counted across every agent the turn starts: see Sub-Agent Limits. - Protected parameters (tenant, auth headers, index configuration) are carried through automatically.
Approvals in delegated agentsโ
A delegated agent's tool call can need the user's approval (see Tool rules). sub_agent_approvals decides what happens:
| Value | Effect |
|---|---|
ask (default) | The approval card appears in the user's chat and the delegated agent waits for the decision |
decline | The call is declined and the delegated agent is told no approval is available |
run | The call runs without asking |
Order of strictness is run, ask, decline. A delegation can only tighten the setting: a per-agent value looser than the provider's is ignored, and an agent a delegated agent delegates to is at least as strict as its parent. sub_agent_approvals comes from the agent setup only; a request's bot_params cannot set it. The task tool has the same setting.
The task tool (spawning anonymous sub-agents for parallel work) comes from the sub-agent tool source, not the delegation provider. See Tools โ Sub-Agent.