Run Sub-Agent
run_sub_agentDelegate a bounded task to a local model with automatic selection, concurrency handling, and cleanup, then log token usage for cost tracking.
Instructions
Delegate one bounded task to a local model. Resolves the model from the profile's registry by roles (or an explicit model_id), acquires a model respecting the profile's concurrency tier (reuse already-loaded, evict on sequential tiers, refuse at parallel capacity), runs the brief once, cleans the reply, unloads exactly once if it loaded the model, and logs exactly one token-usage entry for cost tracking.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"profile": "<profile>",
"brief": "<brief>"
},
"name": "run_sub_agent"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task | No | ||
| brief | Yes | ||
| roles | No | ||
| effort | No | ||
| images | No | ||
| profile | Yes | ||
| model_id | No | ||
| provider | No | ||
| output_schema | No | ||
| reasoning_budget | No | ||
| output_schema_name | No | ||
| system_prompt_override | No |