Skip to main content
Glama

Wait for workers to finish

wait_workers

Block until specified worker processes finish and acceptance commands complete, returning one result row per worker; the 60-second cap reports timed_out so you can call again with the same IDs.

Instructions

Block until the given workers settle (process exited and acceptance run), then return one row each. A call waits 60 seconds at most and says so in timed_out; call again with the same ids. allow_long_wait lifts the cap only when the client's own tool timeout is known to be longer.

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": {
      "task_ids": "<task_ids>"
    },
    "name": "wait_workers"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNoall
compactNoOne short row per worker; the default unless include_events
poll_msNo
task_idsYes
timeout_msNo
event_limitNo
emit_progressNoSend progress notifications while waiting
include_eventsNo
allow_long_waitNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.1

TDQS

A3.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does well on the critical traits: it blocks, it caps at 60 seconds, it signals the cap via timed_out, and re-calling is safe with the same ids. It leaves unstated what happens with unknown or already-finished ids, and how mode=any vs all changes the blocking behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three front-loaded sentences that each earn their place, starting with the blocking behavior and the return shape before the edge-case rules. The allow_long_wait sentence is dense and slightly awkward but carries real information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 9-parameter blocking tool with no annotations and no output schema, the definition covers the core wait/timeout/retry loop adequately. The significant gap is mode semantics and the interaction between timeout_ms and the 60-second cap, which an agent needs to call this correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is only 22% across 9 parameters, so the description must compensate and largely does not. It adds meaning only for task_ids (reuse on retry) and allow_long_wait; mode's any/all semantics, timeout_ms vs the 60s cap, poll_ms, event_limit, include_events, and emit_progress are never explained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Specific verb ('Block until') plus resource ('the given workers') and an explicit definition of the settling condition ('process exited and acceptance run'), plus the return shape ('one row each'). It does not name the non-blocking sibling poll_workers, so the boundary between the two is left to the agent to infer.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete re-invocation guidance ('call again with the same ids') after a timed_out, and a conditional rule for allow_long_wait ('only when the client's own tool timeout is known to be longer'). It stops short of saying when to prefer a non-blocking poll instead of blocking.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.