Skip to main content
Glama
zix-chen
by zix-chen

Write stdin

write_stdin

Poll a running command or write to its stdin using a command_id. Send empty characters to wait for output, or non-empty characters to send input.

Instructions

Poll or interact with a running command by command_id. Empty chars wait for output; non-empty chars writes to stdin. Example: {"command_id":"abc","chars":"","yield_time_ms":10000}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
charsNo
verbosityNopreview
command_idYes
preview_bytesNo
yield_time_msNo
max_output_bytesNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
okYes
errorNo
signalNo
statusNo
stderrNo
stdoutNo
previewNo
summaryNo
warningsNo
exit_codeNo
timed_outNo
truncatedNo
command_idNo
output_refNo
next_actionNo
output_refsNo
next_actionsNo
output_streamNo
output_truncatedNo
stderr_truncatedNo
stdout_truncatedNo
operation_outcomeNo
preview_truncatedNo
stderr_output_bytesNo
stderr_output_linesNo
stderr_truncated_byNo
stdout_output_bytesNo
stdout_output_linesNo
stdout_truncated_byNo
stderr_dropped_bytesNo
stderr_omitted_bytesNo
stdout_dropped_bytesNo
stdout_omitted_bytesNo
truncated_output_streamsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, idempotentHint=false, destructiveHint=false. The description usefully adds the behavioral rule that empty chars waits and non-empty chars writes to stdin, plus a concrete call example, but omits blocking semantics of yield_time_ms and any note on side effects of writing.

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?

Three short sentences, front-loaded with the core mechanism and followed by an immediately usable JSON example. Dense and waste-free, though the example parameter could be trimmed.

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 need not be explained. However, with 6 parameters at 0% schema coverage for a non-idempotent write tool, the description leaves too much of the parameter surface unexplained to be fully complete.

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% across 6 parameters, so the description carries the full burden. It explains chars (empty vs non-empty) and hints at yield_time_ms via the example, but leaves verbosity, preview_bytes, and max_output_bytes completely undocumented in both schema and description.

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 verb and resource: interact with or poll a running command identified by command_id. It conveys the dual purpose (waiting vs writing), but never names the sibling read_output, so an agent must infer which of the two retrieval tools to pick.

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?

Usage is implied by 'running command' and the empty-vs-non-empty chars rule, which tells the agent when to wait versus when to send input. It gives no explicit guidance on when to prefer this over read_output or how long 'wait' actually blocks.

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