Skip to main content
Glama

agy_delegate_edit

Delegate complex multi-file code edits and cross-module refactoring to Antigravity with accept-edits, serialized async execution, and diff-ready summaries.

Instructions

Delegate complex multi-file code modifications or cross-module refactoring to Antigravity (agy) in --mode=accept-edits. SERIALIZATION & ASYNC BUDGET: Calls are serialized (one at a time, AGY_MAX_CONCURRENCY = 1); split edits needing >~8 minutes into smaller scoped calls or fetch in-flight runs via agy_job_result. WHEN TO USE: Coordinated edits across multiple existing files requiring Gemini Argon/Flash reasoning. DO NOT USE FOR: Generating a single standalone boilerplate, DTO, schema, or unit test file (use local_draft_leaf_code instead at 0x quota), read-only analysis (use agy_delegate_research), or running test suites (use local_exec_and_triage). RETURNS: Edit summary, optional IDE visual diff confirmation, and telemetry footer.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "prompt": "<prompt>"
    },
    "name": "agy_delegate_edit"
  }
}

Input Schema

NameRequiredDescriptionDefault
cwdNoOptional working directory path.
tierNoGemini model tier to execute the edit (defaults to argon-medium).argon-medium
promptYesClear multi-file editing instructions and target file scope for Antigravity.
allow_shellNoIf false (default), runs with --mode=accept-edits (file edits only). If true, requests --dangerously-skip-permissions (refused unless AGY_ALLOW_SKIP_PERMISSIONS=1 is configured).
target_filesNoOptional list of target file paths being edited so the Visual HUD can snapshot and open inline diffs (--diff) in Antigravity IDE.
soft_timeout_msNoOptional soft budget in milliseconds before returning an async job_id handle (default 540000 = 540s).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.3.0
    • addedInput schema / properties / soft_timeout_ms
      Added value: +{
      +  "description": "Optional soft budget in milliseconds before returning an async job_id handle (default 540000 = 540s).",
      +  "maximum": 590000,
      +  "minimum": 100,
      +  "type": "number"
      +}
  2. Changed6 schema fields changedv1.2.1
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / allow_shell / default
      Added value: +false
    • changedInput schema / properties / cwd / description
      Previous value: -"Optional working directory."New value: +"Optional working directory path."
    • changedInput schema / properties / prompt / description
      Previous value: -"Clear editing instructions and scope for Antigravity."New value: +"Clear multi-file editing instructions and target file scope for Antigravity."
    • addedInput schema / properties / prompt / minLength
      Added value: +1
    • addedInput schema / properties / tier / default
      Added value: +"argon-medium"
  3. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

Goes well beyond annotations by disclosing serialization (AGY_MAX_CONCURRENCY = 1), the async budget and the ~8-minute splitting heuristic, the soft-timeout-to-job_id fallback, and the return contents (edit summary, visual diff confirmation, telemetry footer). These are operational constraints an agent cannot infer from readOnlyHint/destructiveHint alone and directly shape how it should call the 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?

Front-loaded with purpose, then capped headers for serialization, usage, exclusions, and returns. Dense but zero filler; each clause carries decision-relevant information.

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?

No output schema exists, but RETURNS enumerates the result shape, and the async/job-handle behavior plus the routing to agy_job_result covers the follow-up path. For a 6-parameter mutation tool this is complete enough to invoke correctly on the first try.

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 the schema already documents every parameter; the description adds the valuable behavioral gloss that prompt scope should be sized against the ~8-minute async budget and that tier drives Argon/Flash reasoning. It stops short of explaining the soft_timeout_ms/max 590000 boundary or the allow_shell permission gate, which remain schema-only.

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?

States a specific verb+resource ('Delegate complex multi-file code modifications or cross-module refactoring') and names the execution target and mode ('Antigravity (agy) in --mode=accept-edits'). It is immediately distinguishable from agy_delegate_research and local_draft_leaf_code.

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?

Explicit WHEN TO USE section ('Coordinated edits across multiple existing files requiring Gemini Argon/Flash reasoning') plus a DO NOT USE FOR list that names three alternatives and the exact condition selecting each. This is the full when/when-not/alternative pattern.

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