Skip to main content
Glama

grok_delegate

Delegate coding goals to a headless Grok agent in an isolated git worktree, returning a branch and diffstat without pushing or merging.

Instructions

Delegate a coding goal to local headless grok in an isolated git worktree on a grok/* branch. Returns branch + diffstat. No push, no merge, no --always-approve. Dev-only — not the product admin-bridge.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdNoProject directory to work in; must be an allowlisted root
goalYesCoding goal for the executor
laneYesLane slug or grok/<slug> (not dev/master/main)
modelNoOptional model id
rulesNoOptional extra rules appended to system prompt (bounded)
resumeNoResume session: true for most recent, or a session UUID string
sandboxNoOptional sandbox profile override: off|workspace|devbox|read-only|strict (known built-ins only)
base_refNoGit base ref (default origin/dev)origin/dev
max_turnsNoMax agent turns (server hard-capped at 60)
plan_onlyNoIf true, use read-only permission profile
repo_rootNoAbsolute path to a repo root; accepted only if it resolve()s to an entry on GROK_DELEGATE_ALLOWED_ROOTS (or single GROK_DELEGATE_REPO_ROOT pin)
session_idNoUUID for --session-id (new or forked session name)
json_schemaNoOptional JSON Schema object/string for structured output
fork_sessionNoPass --fork-session (requires resume/continue)
lane_verdictNoAttach the lane verdict schema (default true). The run ends when the executor emits that object, so on a goal it must read the codebase to start, it emits one describing intent and the lane closes empty. Set false for exploration-heavy goals: the executor then works to natural completion and reports prose in summary instead of a parsed verdict.
lanes_parentNoOptional parent dir for worktrees; rejected if inside repo_root or outside GROK_DELEGATE_LANES_PARENT when that env is set
no_subagentsNoIf true, pass --no-subagents
continue_sessionNoPass --continue (most recent for cwd)
reasoning_effortNoOptional reasoning effort (low|medium|high|…)
disable_web_searchNoIf true, pass --disable-web-search
Install Server

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations present, the description bears the full behavioral disclosure burden. It goes beyond a simplistic statement by revealing return content ('branch + diffstat'), safety guarantees (no push/merge/self-approve), and execution isolation (worktree, grok/* branch). It stops short of describing lifecycle/polling or worktree cleanup, but it is meaningfully transparent for an execution tool.

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?

Four compact sentences: purpose, return value, safety constraints, and dev-only scope. Every sentence earns its place; there is no filler. The most important information is front-loaded in the first sentence, making it easy for an agent to quickly grasp what the tool does.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex tool with 20 parameters, no annotations, and no output schema, the description is solid but not complete. It sufficiently covers the tool's purpose, basic return value, and one clear delimitation, but it leaves a notable gap around workflow: whether a call is synchronous, whether the worktree persists, and how it relates to sibling tools like grok_delegate_poll or grok_delegate_status.

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% parameter description coverage, so the description need not restate parameter details. The high-level description adds useful context (lane implies a grok/* branch, goal is a coding goal for the executor), but it does not add significant semantics beyond what schema descriptions already provide.

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 states a specific verb and resource: 'Delegate a coding goal to local headless grok in an isolated git worktree on a grok/* branch.' It clearly differentiates itself from production/admin tooling with 'Dev-only — not the product admin-bridge' and gives a concrete scope for the operation.

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?

It clearly marks the tool as dev-only and declares a key exclusion: 'not the product admin-bridge.' It also communicates important constraints ('No push, no merge, no --always-approve') that shape when this tool is appropriate. However, it does not explicitly name alternative sibling tools or provide decision criteria relative to the many grok_agent_* and grok_delegate_* siblings.

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

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/zai-one/grok-build-mcp'

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