Skip to content

Commit 67ebc01

Browse files
committed
chore: discourage task_list polling
Change-Id: I07b5be1009713ab9b61ccec8a65741c21370d5e0 Signed-off-by: Thomas Kosiewski <tk@coder.com>
1 parent 3831af3 commit 67ebc01

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/common/utils/tools/toolDefinitions.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -475,6 +475,7 @@ export const TOOL_DEFINITIONS = {
475475
task_await: {
476476
description:
477477
"Wait for one or more sub-agent tasks to finish and return their reports. " +
478+
"Use this tool to WAIT; do not poll task_list in a loop to wait for task completion (that is misuse and wastes tool calls). " +
478479
"This is similar to Promise.allSettled(): you always get per-task results. " +
479480
"Possible statuses: completed, queued, running, awaiting_report, not_found, invalid_scope, error.",
480481
schema: TaskAwaitToolArgsSchema,
@@ -490,7 +491,8 @@ export const TOOL_DEFINITIONS = {
490491
task_list: {
491492
description:
492493
"List descendant sub-agent tasks for the current workspace, including their status and metadata. " +
493-
"Use this after compaction or interruptions to rediscover which tasks are still active.",
494+
"Use this after compaction or interruptions to rediscover which tasks are still active. " +
495+
"This is a discovery tool, NOT a waiting mechanism: if you need to wait for tasks to finish, call task_await (optionally omit task_ids to await all active descendant tasks).",
494496
schema: TaskListToolArgsSchema,
495497
},
496498
agent_report: {

0 commit comments

Comments
 (0)