Skip to main content
Glama

Poll Task

poll_task

Polls a task every 20 seconds until it reaches completed, failed, or cancelled status. Use only when the user explicitly asks to wait for or poll a task result.

Instructions

轮询任务直到获得最终结果(仅用户明确要求时使用)

每 20 秒查询一次任务状态,直到任务进入 completed / failed / cancelled 状态。 默认不设置超时;传入 timeout_seconds 可限制最大轮询时长。

⚠️ 重要:Agent 禁止主动调用此工具。ONLY use this tool when the user explicitly asks to wait for or poll a task result (e.g. "帮我等结果"、"轮询一下任务"). 如果用户没有明确表达等待意图,应询问用户而不是直接轮询。

Input Schema

NameRequiredDescriptionDefault
serverNo
task_idYes
timeout_secondsNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.8

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the disclosure burden well: it names the polling interval, the default unbounded timeout, the terminal states, and the strong agent-side restriction on invocation. It does not say what is returned when timeout_seconds expires, which is the one remaining 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.

Conciseness3/5

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

Front-loaded and functional, but the 'only when user explicitly asks' rule is stated twice (in the parenthetical title line and again in the ⚠️ block, restated in both Chinese and English), which is redundant space.

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?

An output schema exists, so return values need not be described. The blocking/polling behavior and invocation guardrails are covered; only the 'server' parameter's meaning and the post-timeout outcome are left open.

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 0%, so the description must compensate. It clarifies timeout_seconds (caps total polling duration, default null = no limit), but says nothing about the 'server' parameter, leaving the target-server selection ambiguous.

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

Purpose5/5

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

States a specific verb and resource — polling a task until it reaches a terminal state — and adds the distinguishing behavioral detail (20s interval, completed/failed/cancelled). This is clearly separable from siblings like get_task (single check) and cancel_task.

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

Usage Guidelines5/5

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

Explicitly says when to use (user explicitly asks to wait/poll, with example utterances) and when not to (agent must not call proactively; ask the user instead). No inference required.

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