Skip to content

Commit 97c2e3f

Browse files
github-actions[bot]claude
authored andcommitted
fix(server): delegate_task explains that supervised runtime modes pause the child
Agents read "read-only reviewer" as a reason to pass runtimeMode: "approval-required". That mode does not restrict the child to reading. On most providers it makes each action that needs approval wait for a person to approve it in the child's thread, which the delegating agent cannot do, so the child stalls while the parent waits for a result that never comes. The runtimeMode parameter had no description. It now says to leave the mode inherited unless the user asks for a supervised child, that narrowing is not a read-only switch, and to state limits in the task instead. The tool description carries the same warning in one line. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
1 parent cc1e634 commit 97c2e3f

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

‎apps/server/src/mcp/toolkits/orchestrator/tools.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ const OrchestratorCapabilitiesTool = Tool.make("orchestrator_capabilities", {
5757

5858
export const DelegateTaskTool = Tool.make("delegate_task", {
5959
description:
60-
"Delegate one task to a T3-owned child agent/subagent of THIS thread and run it with only the supplied task prompt, without copying parent conversation history. Choose providers and models from orchestrator_capabilities, which uses the same live catalog as the composer. Prefer native subagent tools for same-provider work only when they support the chosen model. Use this for any model missing from the native tool, including same-provider work, for cross-provider work, or for explicitly T3-owned child tasks. The childThreadId is backing storage, not an ordinary top-level thread. Provider, model, model options (see orchestrator_capabilities), runtime mode, and interaction mode inherit unless target overrides them. Prefer mode='async' for long work; mode='wait' blocks until completion or timeout. timeoutMs on mode=wait is only the parent's wait budget and does not cancel the child. waitTimedOut on that wait call means the timeout fired; keep that taskId and read status on later task_status. An async child's completion wakes this thread through a notification, steered into active turns where supported or queued otherwise, so end the turn instead of polling or spawning watchers; use task_status only when the result is needed mid-turn.",
60+
"Delegate one task to a T3-owned child agent/subagent of THIS thread and run it with only the supplied task prompt, without copying parent conversation history. Choose providers and models from orchestrator_capabilities, which uses the same live catalog as the composer. Prefer native subagent tools for same-provider work only when they support the chosen model. Use this for any model missing from the native tool, including same-provider work, for cross-provider work, or for explicitly T3-owned child tasks. The childThreadId is backing storage, not an ordinary top-level thread. Provider, model, model options (see orchestrator_capabilities), runtime mode, and interaction mode inherit unless overridden. Leave runtimeMode unset unless the user asks for a supervised child: approval-required and auto-accept-edits usually make the child wait for a person at each action that needs approval. Prefer mode='async' for long work; mode='wait' blocks until completion or timeout. timeoutMs on mode=wait is only the parent's wait budget and does not cancel the child. waitTimedOut on that wait call means the timeout fired; keep that taskId and read status on later task_status. An async child's completion wakes this thread through a notification, steered into active turns where supported or queued otherwise, so end the turn instead of polling or spawning watchers; use task_status only when the result is needed mid-turn.",
6161
parameters: OrchestratorMcpDelegateTaskInput,
6262
success: OrchestratorMcpDelegateTaskResult,
6363
failure: OrchestratorMcpFailure,

‎packages/contracts/src/orchestratorMcp.ts‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,12 @@ export const OrchestratorMcpDelegateTaskInput = Schema.Struct({
184184
"Wait budget for mode=wait only. Default 10 minutes. Elapsing it returns waitTimedOut=true on that call and does not cancel the child.",
185185
}),
186186
clientRequestId: Schema.optional(OrchestratorMcpClientRequestId),
187-
runtimeMode: Schema.optional(OrchestratorMcpRuntimeMode),
187+
runtimeMode: Schema.optional(
188+
OrchestratorMcpRuntimeMode.annotate({
189+
description:
190+
"Defaults to inherit; omit it unless the user asks for a supervised child. A narrower mode is not a read-only switch: on most providers, approval-required and auto-accept-edits pause the child at each action that needs approval until a person approves it in the child's thread, which this thread cannot do. To limit what the child does, say so in the task. A mode broader than this thread's is rejected.",
191+
}),
192+
),
188193
interactionMode: Schema.optional(OrchestratorMcpInteractionMode),
189194
});
190195
export type OrchestratorMcpDelegateTaskInput = typeof OrchestratorMcpDelegateTaskInput.Type;

0 commit comments

Comments
 (0)