Skip to main content
Glama

read_output

Read-only

Poll new output from a running command without sending input. Use after execute returns status='partial' for non-interactive commands.

Instructions

Poll new output from a running command without sending input. Use after
execute returns status="partial" for non-interactive commands (builds,
training loops, long searches).

Each call returns only output produced since the last read. When the
command finishes, status changes to "completed" and the command_id is
retired — further calls raise ValueError.

WHEN NOT TO USE: If the command expects input, use respond. If you
need to interrupt or send keys, use send_control.

PARAMETER GUIDANCE: pause_timeout is the primary dial — it controls
how long to wait when the command is silent. total_timeout only caps
actively streaming output and has no effect during silence.

ERRORS: Raises ValueError if command_id is invalid or already completed.

RETURNS:
- {"status": "partial", "output": str, "command_id": str}
- {"status": "completed", "output": str, "exit_code": int}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
command_idYesThe command_id from a status='partial' response. Raises ValueError if invalid or already completed
pause_timeoutNoSeconds of silence before returning. Primary dial for polling — raise it (e.g. 30, 60) for quiet jobs instead of total_timeout. Must be > 0 and ≤ total_timeout
total_timeoutNoHard cap on call duration in seconds. Only binds while output is streaming — silent polls return at pause_timeout. Must be ≥ pause_timeout
Behavior5/5

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

Discloses key behaviors beyond readOnlyHint: incremental output (each call returns new output since last read), command lifecycle (retired on completion, future calls raise ValueError), and error conditions. No contradiction with readOnlyHint or openWorldHint.

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?

Well-structured with sections like 'WHEN NOT TO USE', 'PARAMETER GUIDANCE', 'ERRORS', 'RETURNS'. Every sentence adds value; no filler. Concise yet comprehensive.

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

Completeness5/5

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

Despite no output schema, the description fully documents return types with structure and meaning. Covers error scenarios, lifecycle, polling semantics. Complete for a polling tool of moderate complexity.

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

Parameters5/5

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

Schema coverage is 100% (baseline 3), but the description adds significant value by explaining the roles of pause_timeout vs total_timeout: 'pause_timeout is the primary dial... total_timeout only caps actively streaming output.' This clarifies behavior beyond schema comments.

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?

The description starts with a clear verb+resource: 'Poll new output from a running command without sending input.' It distinguishes itself from siblings like 'respond' and 'send_control' by specifying when to use each.

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?

Provides explicit when-to-use: 'Use after execute returns status="partial" for non-interactive commands.' Also includes a 'WHEN NOT TO USE' section with direct alternatives (respond, send_control), guiding the agent clearly.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/QiuwenZheng/interminal'

If you have feedback or need assistance with the MCP directory API, please join our Discord server