Skip to main content
Glama

execute_plan

Idempotent

Validate and run a geoprocessing plan step by step; invalid plans run nothing, step outputs resolve by reference, and per-step provenance manifests record results.

Instructions

Validate, then execute a geoprocessing plan step by step.

The plan is re-validated first (an invalid plan runs nothing). Steps run in order; "$step_id" references resolve to the outputs of earlier steps. Every step writes its own provenance manifest, and a plan-level manifest (.plan.json, with the plan sha256 and per-step outcomes) ties them together. Execution stops at the first failing step; outputs already produced stay on disk with their manifests. Same plan format as validate_plan — validate first, then execute.

A step_warnings key in the response means the plan ran but some step produced a suspicious result (an empty output, non-overlapping inputs): read it before treating a completed plan as a correct one.

Verification failures include structured checks and a three-attempt repair budget. To retry, change the plan yourself, choose NEW output paths and pass the previous .plan.json as repair.previous_manifest. MapSmith never chooses or runs the repair for you; every attempt is linked in the manifests and a fourth is refused.

Input Schema

NameRequiredDescriptionDefault
planYes
repairNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.11.0
    • addedInput schema / $defs / OutputContract
      Added value: +{
      +  "additionalProperties": false,
      +  "description": "What a branch promises to return, independently of its operation name.",
      +  "properties": {
      +    "cardinality": {
      +      "default": "unknown",
      +      "enum": [
      +        "one",
      +        "fewer",
      +        "more",
      +        "same_as_input",
      +        "unknown"
      +      ],
      +      "title": "Cardinality",
      +      "type": "string"
      +    },
      +    "geometry": {
      +      "anyOf": [
      +        {
      +          "enum": [
      +            "point",
      +            "line",
      +            "polygon"
      +          ],
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ],
      +      "default": null,
      +      "title": "Geometry"
      +    },
      +    "kind": {
      +      "enum": [
      +        "vector",
      +        "raster",
      +        "table",
      +        "number",
      +        "map",
      +        "description"
      +      ],
      +      "title": "Kind",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "kind"
      +  ],
      +  "title": "OutputContract",
      +  "type": "object"
      +}
    • addedInput schema / $defs / PlanStep / properties / output
      Added value: +{
      +  "anyOf": [
      +    {
      +      "$ref": "#/$defs/OutputContract"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Expected branch output: kind, optional geometry and cardinality"
      +}
  2. Changed2 schema fields changedv0.10.1
    • addedInput schema / $defs / RepairRequest
      Added value: +{
      +  "additionalProperties": false,
      +  "description": "A protocol-level retry linked to the failed plan's durable manifest.",
      +  "properties": {
      +    "previous_manifest": {
      +      "description": "The .plan.json returned by the failed attempt",
      +      "maxLength": 4096,
      +      "title": "Previous Manifest",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "previous_manifest"
      +  ],
      +  "title": "RepairRequest",
      +  "type": "object"
      +}
    • addedInput schema / properties / repair
      Added value: +{
      +  "anyOf": [
      +    {
      +      "$ref": "#/$defs/RepairRequest"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
  3. First observedv0.3.0

TDQS

A4.6/5.0
Behavior5/5

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

Goes well past the annotations: it names the failure mode (stop at first failing step, prior outputs and manifests persist), the provenance artifacts written (per-step manifest plus <last output>.plan.json with plan sha256), the meaning of step_warnings, and the hard three-attempt repair cap with a fourth refused. The repair path requiring new output paths is the kind of operational caveat annotations cannot express.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action, then sequenced into validation, execution, warnings, and repair paragraphs — each sentence carries weight. The closing paragraph on the repair budget is dense and slightly repetitive with the earlier manifest discussion, but nothing is truly wasted.

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?

For a complex multi-step executor with an output schema available, the description covers the full operational envelope: pre-validation, step ordering and references, provenance, partial-failure semantics, warning interpretation, and the retry protocol. Nothing an agent needs before invoking it is missing.

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 reported as 0%, so the description must carry the load, and it does: it explains that '$step_id' strings resolve to earlier step outputs, that the plan is re-validated before anything runs, and what repair.previous_manifest expects (the prior .plan.json). It stops short of describing the output contract fields (kind/geometry/cardinality), leaving that to the schema.

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?

Opens with a specific verb-plus-resource: 'Validate, then execute a geoprocessing plan step by step.' This clearly separates it from validate_plan (validation only) and run_operation (single operation), so an agent can pick it without opening the schema.

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?

Explicitly routes the agent: 'Same plan format as validate_plan — validate first, then execute,' and explains when to use the repair path ('change the plan yourself, choose NEW output paths'). It never contrasts with run_operation for single-step work, so the routing guidance is clear but not exhaustive.

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