Skip to main content
Glama

run_task

Execute a development task with automated verify and auto-fix cycles, returning structured evidence of attempts and changes.

Instructions

ORCHESTRATED + MUTATING: run a full execute → git-evidence → verify → auto-fix loop server-side and return structured evidence (attempts, changed files, diff, verify output). Same approval bar as execute_task: only after the user approved a plan. Prefer this over execute_task when a test/build command can verify the work. If the result has status 'needs_advisor', answer the question via continue_task with the returned session_id. cancel_task also aborts in-flight grok sub-processes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdYesAbsolute path to the target project working directory
modelNoOptional Grok model id (defaults to CLI / MCP_GROK_MODEL)
promptYesTask instructions for Grok (be specific about files, tests, constraints)
max_turnsNoMax agentic turns for Grok
backgroundNoIf true, start Grok in background and return job_id immediately
session_idNoOptional UUID to create/resume a named Grok session
timeout_secNoTimeout in seconds (default 600)
verify_commandNoShell command run in cwd after execution (e.g. 'npm test'). Omitted → git evidence only.
max_fix_attemptsNoAuto-fix rounds when verify_command fails (default 2; 0 disables)
verify_timeout_secNoTimeout in seconds for each verify_command run (default 300)
Behavior5/5

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

With no annotations provided, the description fully carries the behavioral burden. It clearly labels the tool as 'MUTATING', discloses the approval requirement, describes the server-side orchestration loop, and explains side effects on sub-processes via cancel_task. It also states the structured return content, giving the agent a clear picture of what to expect.

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?

The description is dense but every sentence is purposeful: it states the core loop, the approval requirement, the preferred alternative, the needs_advisor handling, and the cancel behavior. It front-loads the most important identifiers ('ORCHESTRATED + MUTATING') and avoids filler.

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?

Given a complex tool with 10 parameters, no output schema, and no annotations, the description nevertheless covers the workflow, approval constraints, conditional branching via status, and alternative tool selection. It is complete enough for an agent to decide when to invoke it and how to interpret the result.

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 each parameter is already documented. The description adds workflow-level meaning by explaining how verify_command relates to the auto-fix loop and how session_id is used with continue_task. This connects parameters to the overall flow, exceeding the baseline without needing to repeat schema details.

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?

The description opens with a precise verb and resource: 'run a full execute → git-evidence → verify → auto-fix loop server-side and return structured evidence.' It clearly distinguishes the tool from execute_task while listing concrete outputs (attempts, changed files, diff, verify output). This goes well beyond a generic 'runs a task' statement.

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?

The description gives explicit usage guidance: 'Prefer this over execute_task when a test/build command can verify the work.' It also states the same approval bar as execute_task, specifies how to handle 'needs_advisor' via continue_task, and notes cancel_task aborts in-flight sub-processes. This is model guidance, not just a hint.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/emigrete/mcp-grok-executor'

If you have feedback or need assistance with the MCP directory API, please join our Discord server