Skip to main content
Glama

获取 DSH 任务结果

dsh_result
Read-only

Retrieves a completed task's final output, exit code, and duration; oversized output is saved to a file and its path returned, while unfinished tasks return an error.

Instructions

任务结束后获取最终结果(含完整输出、退出码、耗时)。输出过大时会自动落盘并返回文件路径。任务未结束时返回错误。

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": {
      "task_id": "<task_id>"
    },
    "name": "dsh_result"
  }
}

Input Schema

NameRequiredDescriptionDefault
task_idYesdsh_run 返回的任务 id

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.2

TDQS

A4/5.0
Behavior4/5

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

The annotations only declare readOnlyHint and openWorldHint; the description adds real behavior beyond them — oversized output is spilled to a file and a path is returned instead of inline content, and the call fails if the task is unfinished. It does not say whether the result is consumed/expired after retrieval, which matters for repeat calls.

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?

Three compact sentences, each carrying a distinct fact (what is returned, large-output handling, failure condition), with the core purpose front-loaded. No filler.

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?

With no output schema, the description does the necessary work of listing the return fields and the two edge cases (output spill-to-disk, unfinished task). It is nearly complete for a one-parameter read tool, with the only gap being how this differs from dsh_read_result.

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% and the single parameter task_id is already documented as "dsh_run 返回的任务 id". The description adds no further meaning about the identifier, so the neutral baseline applies.

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 description gives a specific verb plus resource: fetch the final result of a DSH task, and it enumerates the payload contents (full output, exit code, duration). It is clear on its own, but it never distinguishes itself from the sibling dsh_read_result, which an agent could plausibly confuse with it.

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?

"任务未结束时返回错误" establishes an explicit when-not condition, effectively telling the agent to wait for completion (e.g. via dsh_status) before calling. It stops short of naming the alternative tools or a polling pattern, so it is not a full when/when-not/alternatives treatment.

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