Skip to main content
Glama

Run a GLM sub-agent

glm_agent
Destructive

Delegate a self-contained coding task to a GLM sub-agent that works in a specified project folder and returns only a summary and changed files, saving Claude tokens.

Instructions

Delegate a self-contained coding task to a GLM sub-agent (use when the user asks for GLM or glm_agent, or wants to save Claude tokens). GLM works inside workdir with its own read/write/edit/list/bash tools and returns a summary plus the list of changed files. Give a complete task description (goal, constraints, how to verify); GLM does not see this conversation. workdir must be an absolute path. File tools cannot leave workdir; bash is not sandboxed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskYesComplete, self-contained task for the sub-agent.
modelNoGLM model id. Default glm-5.3. Coding Plan models: glm-5.3, glm-5.3-flash.
contextNoOptional extra background or constraints.
workdirYesAbsolute path of the directory GLM works in.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior5/5

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

Adds substantial behavior beyond the annotations: GLM runs with its own read/write/edit/list/bash tools inside workdir, returns a summary plus the list of changed files, does not see this conversation, file tools are confined to workdir, and bash is explicitly NOT sandboxed. The last point is a critical safety disclosure that no annotation conveys.

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-loads the purpose and trigger, then layers behavioral and safety constraints in dense parenthetical-free sentences. Each sentence earns its place; it is slightly long but not padded.

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?

With no output schema, the description still specifies the return ('a summary plus the list of changed files'), the sandboxing boundary, the absolute-path requirement, and the isolation from this conversation. An agent has everything needed to call this correctly and safely.

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 all four parameters are already documented. The description reinforces the two required params (absolute workdir, complete self-contained task) and hints at why 'context' exists via 'GLM does not see this conversation', but adds no syntax or format detail beyond the schema. Baseline 3 is correct.

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 self-contained coding task to a GLM sub-agent') and immediately establishes scope and the nature of the delegate. An agent can tell exactly what this does without inspecting the schema, and there are no siblings to confuse it with.

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?

Gives explicit trigger conditions ('use when the user asks for GLM or glm_agent, or wants to save Claude tokens') and the qualifier that the task be self-contained. It stops short of stating when not to delegate, but the 'self-contained' constraint and the token-saving rationale cover the practical decision well.

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

Deploy Server

Other Tools