Skip to main content
Glama

Delegate (sync)

grok_delegate

Delegate a coding goal to local headless Grok in an isolated git worktree on a grok/* branch; returns branch and diffstat, no push or merge.

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

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

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.26.1
    • addedInput schema / properties / cwd
      Added value: +{
      +  "description": "Project directory to work in; must be an allowlisted root",
      +  "type": "string"
      +}
  2. First observedv0.4.1

TDQS

A3.8/5.0
Behavior4/5

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

Annotations declare a non-read-only, open-world, non-idempotent, non-destructive write. The description usefully adds the safety envelope (isolated worktree, no push, no merge, no --always-approve) and the sync return (branch + diffstat), which is real context beyond the annotations. It stops short of noting auth/permission prerequisites or failure modes.

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?

Three tight sentences, front-loaded with the action and scope, then the return value, then the negative constraints. Every clause earns its place with no filler.

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 20-parameter mutation tool with no output schema, the description adequately conveys the operation, its boundaries, and its return shape, while annotations carry the safety profile. It is complete enough to call correctly, though the routing relationship to the other grok_delegate_* tools is left implicit.

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 the schema already documents all 20 parameters in detail. The description adds no parameter-level meaning (e.g., it does not explain the lane_verdict vs plan_only interaction or the allowlist constraints), so it neither helps nor hurts beyond the baseline.

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?

States a specific verb (delegate) and resource (coding goal to local headless grok in an isolated git worktree on a grok/* branch), plus the sync return (branch + diffstat). It clearly says what it is not (the product admin-bridge, dev-only), but it never distinguishes itself from the very similar sibling grok_delegate_start/plan, which the agent must infer from the '(sync)' title.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Offers some when-not guidance: 'Dev-only — not the product admin-bridge' and 'No push, no merge, no --always-approve' bound the intended context. However it gives no explicit rule for choosing this tool over grok_delegate_start, grok_delegate_plan, or grok_agent_execute, leaving the primary routing decision to inference.

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