Skip to main content
Glama

plan_print_recovery

Read-only

Plan a recovery strategy for a failed 3D print from the printer name, job ID, and failure type, using the latest checkpoint to return actionable resume or recovery steps.

Instructions

Plan a recovery strategy from a printer + job + failure type.

Convenience wrapper that synthesizes a :class:`FailureReport` from
the supplied args (using the latest checkpoint for the printer/job
when available) and runs it through the same planner used by
``plan_failure_recovery``.

**Which recovery tool to use:**

- Have a printer_name + job_id from a failed print? → ``plan_print_recovery`` (this tool)
- Have a failure_id from ``detect_print_failure``? → ``plan_failure_recovery``

Args:
    printer_name: Name of the printer that failed.
    job_id: The failed job's identifier.
    failure_type: Type of failure (thermal_runaway, layer_shift,
        adhesion_failure, filament_runout, nozzle_clog,
        communication_loss, power_loss, blob_detected, spaghetti,
        stringing, warping).  Defaults to ``communication_loss``.
    part_attached: Your word on whether the half-printed part is still
        stuck to the plate (true / false).  Left out, a resume Kiln
        would build is held back and the plan says so.
    try_untested_resume: Opt this printer in to a resume Kiln has not
        yet seen work on its model; Kiln learns from how it goes.

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": {
      "printer_name": "<printer_name>",
      "job_id": "<job_id>"
    },
    "name": "plan_print_recovery"
  }
}

Input Schema

NameRequiredDescriptionDefault
job_idYesThe failed job's identifier.
failure_typeNoType of failure (thermal_runaway, layer_shift, adhesion_failure, filament_runout, nozzle_clog, communication_loss, power_loss, blob_detected, spaghetti, stringing, warping). Defaults to ``communication_loss``.
printer_nameYesName of the printer that failed.
part_attachedNoYour word on whether the half-printed part is still stuck to the plate (true / false). Left out, a resume Kiln would build is held back and the plan says so.
try_untested_resumeNoOpt this printer in to a resume Kiln has not yet seen work on its model; Kiln learns from how it goes. Default: false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv1.5.1
    • addedInput schema / properties / failure_type / description
      Added value: +"Type of failure (thermal_runaway, layer_shift, adhesion_failure, filament_runout, nozzle_clog, communication_loss, power_loss, blob_detected, spaghetti, stringing, warping).  Defaults to ``communication_loss``."
    • addedInput schema / properties / job_id / description
      Added value: +"The failed job's identifier."
    • addedInput schema / properties / part_attached
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "boolean"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Your word on whether the half-printed part is still stuck to the plate (true / false).  Left out, a resume Kiln would build is held back and the plan says so.",
      +  "title": "Part Attached"
      +}
    • addedInput schema / properties / printer_name / description
      Added value: +"Name of the printer that failed."
    • addedInput schema / properties / try_untested_resume
      Added value: +{
      +  "description": "Opt this printer in to a resume Kiln has not yet seen work on its model; Kiln learns from how it goes. Default: false.",
      +  "title": "Try Untested Resume",
      +  "type": "boolean"
      +}
  2. Changed1 schema field changedv1.5.0
    • removedInput schema / properties / failure_type / default
      Removed value: -null
  3. First observedv0.1.0

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false and openWorldHint=false, and the description stays consistent with a pure planning operation. Beyond that, it discloses real behavior: the report is synthesized from the latest checkpoint when available, omitting part_attached suppresses a resume the system would otherwise build, and try_untested_resume opts a printer into learning. It doesn't say what the resulting plan contains, but the behavioral additions are substantive.

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?

The selection guidance is front-loaded in a scannable bullet list and the opening sentence is tight. The 'Args:' section duplicates schema text that an agent already receives, adding length without new information, which keeps it short of a 5.

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?

There is no output schema, and the description never says what a 'plan' actually returns — whether it contains resume actions, gcode steps, or a safety verdict — leaving the agent unable to anticipate the result shape. The tool-selection and optional-parameter semantics are complete, but the return-side gap matters for a planner whose whole value is its output.

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 five parameters. The 'Args:' block largely restates the schema descriptions verbatim rather than adding format, range, or interaction detail, so it does little work beyond the structured field.

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 first line gives a specific verb and resource ('Plan a recovery strategy from a printer + job + failure type'), and the body explains this is a convenience wrapper that synthesizes a FailureReport and runs it through the same planner as plan_failure_recovery. The 'Which recovery tool to use' section makes the boundary against the sibling unambiguous.

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?

It explicitly enumerates the two selection conditions: having printer_name + job_id selects this tool, having a failure_id from detect_print_failure selects plan_failure_recovery. No inference is required to pick between them, and it also explains the omittable part_attached case.

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

Deploy Server

Other Tools