glm_delegate
Delegate coding tasks to a fresh subagent that runs independently, with a verification command to prove completion. Returns immediately, enabling parallel or asynchronous work.
Instructions
Start a new Claude Code subagent on a task.
Returns immediately with an agent_id and run_id unless wait_seconds is set. Each call creates a fresh agent with its own runtime process and session; use glm_continue to give more work to an agent that already exists.
Args: task: What to do, with a clear definition of done. The child cannot ask you clarifying questions, so state the acceptance criteria. verification: The shell command that proves the task is done, run by this server in the workspace after the child finishes — e.g. "pytest -q" or "npm test && npm run lint". Its exit code decides whether the run is reported completed or completed_unverified. Pass "true" if there is genuinely nothing to check. workspace: Directory the child reads and writes. Relative paths resolve against the server's configured workspace. Defaults to that workspace. instructions: Optional standing guidance prepended to the task, e.g. coding conventions or files to leave alone. model: GLM model id. Defaults to the server's configured model. name: Human label for this agent, shown in glm_list. wait_seconds: Block up to this long for the run to finish. 0 returns at once.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | ||
| task | Yes | ||
| model | No | ||
| workspace | No | ||
| instructions | No | ||
| verification | Yes | ||
| wait_seconds | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||