Skip to main content
Glama

Start a ZCode subagent task

zcode_run
Destructive

Delegate a self-contained task to a background GLM subagent in the ZCode desktop app and get a taskId immediately; then block or poll for the finished result.

Instructions

Delegate a task to a GLM subagent running in the official ZCode desktop app (uses the user's GLM Coding Plan quota). Returns a taskId immediately; the task runs in the background. Use zcode_wait to block until it finishes, or zcode_status to poll. The subagent runs with FULL ACCESS (shell, file read/write anywhere the OS user can) in the project folder /root/projects/subagents. It cannot see this conversation, so put ALL needed context in the prompt: goal, absolute file paths, constraints, and the exact output format you want back. Prefer small, well-scoped tasks. Several tasks may run in parallel (limit 3). Models: GLM-5.3 | GLM-5.3-Flash (default GLM-5.3; Flash is faster and cheaper for simple work). provider picks the billing route (the model menu lists the same names under both): account%3Abigmodel-individual-coding-plan = BigModel 个人 (default), account%3Abigmodel-start-plan = Start Plan 免费.

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": {
      "prompt": "<prompt>"
    },
    "name": "zcode_run"
  }
}

Input Schema

NameRequiredDescriptionDefault
modelNoModel to use. Default GLM-5.3.
promptYesComplete, self-contained task description.
providerNoBilling route (provider). Default account%3Abigmodel-individual-coding-plan = BigModel 个人; account%3Abigmodel-start-plan = Start Plan 免费 (the decoded form account:… works too). Others are refused.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true and openWorldHint=true, but the description goes further: it discloses that the call returns a taskId immediately, that work happens in the background, that the subagent has FULL ACCESS to shell and filesystem, that it runs in /root/projects/subagents, that it consumes the user's GLM Coding Plan quota, and that it cannot see this conversation. That is exactly the extra context the annotations cannot carry.

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?

Front-loaded with the core action and the follow-up routing before the operational caveats. It is dense but nearly every sentence carries decision-relevant information; the provider enumeration is somewhat verbose and partially duplicates the schema's own provider description.

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?

For an open-world, destructive, background-executing tool with no output schema, the definition covers everything an agent needs: return value shape (taskId), execution model (background, parallel limit 3), access scope and working directory, context-isolation warning, quota implications, and the follow-up tools. No material gap remains.

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

Parameters4/5

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

Schema coverage is 100%, so the schema already defines all three parameters; the description nonetheless adds selection meaning, notably that Flash is preferable for simple work and that the provider value selects a billing route with a decoded form also accepted. The prompt guidance (absolute paths, constraints, exact output format) reinforces rather than merely repeats the schema's "self-contained task description."

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 ("Delegate a task to a GLM subagent running in the official ZCode desktop app") and immediately distinguishes itself from siblings by naming zcode_wait and zcode_status as the blocking/polling counterparts. An agent can tell this is the fire-and-forget launcher versus the wait/status/structured/batch variants without opening another schema.

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?

Explicit routing: "Use zcode_wait to block until it finishes, or zcode_status to poll." Adds task-shaping guidance ("Prefer small, well-scoped tasks"), parallel capacity ("limit 3"), model selection criteria (Flash "faster and cheaper for simple work"), and which provider routes are accepted vs refused.

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