Skip to main content
Glama

orca_wait

Block server-side until a worker finishes, fails, or needs human input, then return one structured event with status and last message; call in a loop to walk through events.

Instructions

Block server-side until a worker finishes or needs a human, then return one structured event (state done, failed, waiting or blocked, plus the worker and its last message). With a run (or a dispatch, or a run this server created) it waits on the Run's worker_done and escalation mail without taking it and, at the same time, on Orca's hook state (a worker parked on a prompt never mails); otherwise on hook state alone for one terminal, one worktree, or every worker this client started. Each event is returned once, so calling orca_wait in a loop walks through them. On state working the timeout passed: wait again.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "orca_wait"
  }
}

Input Schema

NameRequiredDescriptionDefault
runNo
dispatchNo
terminalNo
worktreeNoAbsolute path
timeoutMsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.9/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 mostly does: it discloses server-side blocking, one event per call, each event returned exactly once (so looping is required), that escalation mail is observed without being consumed, and that a worker parked on a prompt is caught via hook state rather than mail. The main gaps are the timeout bounds and any concurrency or failure behavior, though the timeout ceiling is documented in the schema.

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

Conciseness3/5

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

The opening sentence is front-loaded and clear, but the second sentence is a long chain of nested clauses (with a run, or a dispatch, or a run this server created / without taking it / and at the same time on hook state) that is hard to parse on first read. The content earns its place, but the structure could be broken into shorter statements.

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

Completeness4/5

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

For a five-parameter blocking tool with no annotations and no output schema, the description covers what the agent needs: the returned event's state vocabulary and payload, the one-event-per-call consumption model, and the timeout-loop behavior. Only the interaction between mutually exclusive scope parameters and the timeout limits remain unstated.

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

Parameters4/5

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

Schema description coverage is only 20% (worktree alone is documented as an absolute path), so the description must compensate, and it does: run, dispatch, run-this-server-created, terminal, worktree, and the all-workers default are each mapped to a waiting scope. timeoutMs is referenced implicitly through the working/timeout remark. What is missing is what happens if run and dispatch are both supplied.

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?

The first sentence gives a specific verb and resource: block server-side until a worker finishes or needs a human, then return one structured event with state (done, failed, waiting, blocked) plus the worker and its last message. That is far more informative than the name alone. It only partially separates itself from siblings like orca_terminal_wait or orca_check, which the agent must 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?

It states the condition for use (waiting for a worker to finish or escalate to a human) and gives operational guidance: call in a loop to walk events, and on state working the timeout elapsed so wait again. It also scopes usage by argument: with a run/dispatch it waits on mail plus hook state, otherwise hook state alone. It does not name when to prefer a sibling such as orca_check or orca_terminal_wait instead.

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