Skip to main content
Glama

agent_wait

Read-onlyIdempotent

Pauses until an AI agent reaches a settled state—idle, done, or blocked—or a state you specify, so you can synchronize workflows and detect completion or stalls.

Instructions

Wait until an agent reaches a settled state (idle, done or blocked by default, or any state in until).

Input Schema

NameRequiredDescriptionDefault
untilNo
targetYes
timeout_msNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnly, idempotent and non-destructive, so the safety profile is covered. The description adds the useful default-state set, but for a blocking wait it omits what happens on timeout expiry (error vs. current-state return) even though a 120s default timeout exists, which is a real behavioral gap.

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?

A single front-loaded sentence with no waste, leading with the verb and the outcome. It is appropriately sized, though that brevity is part of why parameter and timeout behavior go unexplained.

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?

An output schema exists, so return values needn't be described. Still, for a three-parameter blocking tool with zero schema coverage, the definition leaves how to identify a target and what a timeout does unaddressed, which an agent needs to invoke it confidently.

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 description coverage is 0%, so the description must carry parameter meaning. It partially covers 'until' (settled states plus override), but 'target' is never defined (agent id? name? handle?) and 'timeout_ms' is never mentioned despite its 120000 default and the tool's blocking nature.

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 description states a specific verb (wait) and resource (agent state), and enumerates the settled states it resolves on. It does not name or distinguish itself from waiting siblings like pane_wait_output or events_wait, so the agent must infer which wait tool applies.

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

Usage Guidelines3/5

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

It explains the default settle set (idle, done, blocked) and how 'until' overrides it, which implies usage. But there is no explicit "use this when you need X instead of pane_wait_output/events_wait" guidance and no stated preconditions such as needing a live agent target.

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