Skip to main content
Glama

agent_output

Retrieve a spawned agent's final message and optional recent transcript messages to verify results and inspect session activity before trusting reported success.

Instructions

The agent's last final message, plus optionally the last N transcript messages. Do not treat a worker's claim of success as proof: check its diff and run the tests yourself.

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": {
      "id": "<id>"
    },
    "name": "agent_output"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesjcode session id returned by spawn_agent
tailNoTranscript messages to include

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?

With no annotations, the description carries the full burden and does disclose the return contract at a high level (last final message plus optional transcript) and adds a caution about not trusting worker claims of success. It omits important behavioral facts: whether it errors or returns empty for a still-running or unknown session, and whether 'last final message' implies the agent must have finished.

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?

Two short sentences, front-loaded with what the tool returns. The verification caution is slightly tangential to describing the call but is short and plausibly useful, so it does not meaningfully dilute the definition.

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?

There is no output schema, so the description must carry the return shape, and it only partially does: it says what content comes back but not the structure (single string vs. object with a transcript array) or ordering. Combined with unstated behavior for non-existent or in-progress sessions, a would-be caller still has gaps.

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 description coverage is 100%, so both parameters (id, tail) are already documented in the schema, including that id comes from spawn_agent and tail is a message count. The description's 'last N transcript messages' only restates the tail semantics, so baseline 3 is appropriate.

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 first sentence names a specific resource and scope: the agent's last final message, with an optional tail of transcript messages. That is concrete enough to distinguish it from siblings like agent_status or list_agents, though it never names those alternatives explicitly and leaves the retrieval verb implicit.

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

Usage Guidelines2/5

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

There is no explicit when-to-use guidance and no routing against siblings such as agent_status or wait_agents, even though an agent could plausibly confuse 'get output' with 'get status'. The second sentence is a verification caution rather than a usage rule, so the agent must infer when this tool is the right call.

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