Skip to main content
Glama

execute_task

Delegate implementation tasks to Grok for file edits, test runs, and shell commands. Use after user approval to execute code changes and return a session ID for continued work.

Instructions

MUTATING: Delegate implementation to Grok (file edits, tests, shell). Uses --always-approve. Only call after the user approved a plan or explicitly asked to implement. Verify with git diff/tests afterwards. Returns session_id for continue_task.

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 for multi-step work
timeout_secNoTimeout in seconds (default 600)
Behavior4/5

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

With no annotations, the description carries full behavioral burden. It opens with 'MUTATING:', clearly flags side effects, and reveals the 'Uses --always-approve' behavior. It also mentions the scope of actions (file edits, tests, shell) and output (session_id). Missing some details like reversibility, but still strong.

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 four sentences, each adding distinct value: mutation warning, purpose, usage condition, verification, and output. It is front-loaded with 'MUTATING' and avoids filler. Every sentence earns its place.

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?

For a mutation tool with 7 parameters and no output schema, the description covers approval prerequisites, verification steps, and the returned session_id. It does not elaborate on background execution or timeout behaviors, but the schema covers those. The description is sufficiently complete for agent decision-making.

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?

The input schema has 100% coverage with descriptions for all 7 parameters, so the baseline is 3. The description does not add parameter-specific semantics, but it doesn't need to given schema richness. It mentions the session_id return value, which relates to an output concept, not parameter meaning.

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 clearly states the tool's purpose: 'Delegate implementation to Grok (file edits, tests, shell)'. It distinguishes itself from siblings by noting it 'Returns session_id for continue_task', implying a handoff workflow. However, it does not explicitly contrast with the sibling run_task.

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 provides explicit usage conditions: 'Only call after the user approved a plan or explicitly asked to implement'. It also gives post-usage guidance: 'Verify with git diff/tests afterwards'. This is clear, actionable, and addresses when-not-to-use.

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