Skip to main content
Glama

Wait for text

wait_for
Read-only

Waits for specified text, such as a code verdict like 'Accepted' or 'Wrong Answer', to appear on the page after submission, with a configurable timeout.

Instructions

Wait until some text appears on the page. Use after Run/Submit to wait for the verdict, e.g. 'Accepted' or 'Wrong Answer'.

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": {
      "text": "<text>"
    },
    "name": "wait_for"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesText to wait for
timeoutMsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is covered. The description adds the intended usage timing but omits the most important behavioral fact for a wait tool: what happens on timeout (error, false, or silent return) and whether matching is substring, exact, or case-sensitive. That gap matters even with annotations present.

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

Conciseness5/5

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

Two short sentences, purpose first and usage second, with zero filler. Every clause carries 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 two-parameter tool with no output schema, the definition covers intent and a good example but leaves return-value and timeout behavior undefined. An agent can call it, but cannot reason about failure handling.

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

Parameters3/5

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

Schema coverage is 50%: 'text' only gets the tautological schema note 'Text to wait for', and timeoutMs has bounds but no explanation. The description partially compensates by showing what kind of string to pass ('Accepted', 'Wrong Answer'), but says nothing about matching semantics or timeout behavior, leaving the compensation incomplete.

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?

States a specific action and target: 'Wait until some text appears on the page.' That is clearly distinct from siblings like get_content (immediate retrieval) or click_element, though no sibling is named explicitly.

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 a concrete trigger ('Use after Run/Submit') and a real example of the awaited text ('Accepted', 'Wrong Answer'), which is exactly the context an agent needs. It stops short of stating when not to use it or what to do instead if the text never appears.

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