Skip to main content
Glama

smart_reprint

Destructive

Reprint an existing model in a chosen material by finding the file, selecting the loaded AMS slot, adjusting slicer settings, reslicing, and starting the print.

Instructions

Smart one-shot material-switch reprint — finds the model, detects the right AMS slot, adjusts slicer settings, and prints.

This is the highest-level reprinting tool. Give it a file name (or
partial name) and a target material, and it handles everything:

1. **Find the model**: Searches print history for the file name, then
   searches common local directories for the source STL/3MF/STEP file.
2. **Check AMS**: Reads AMS tray status to find which slot has the
   target material loaded. Auto-selects the matching slot.
3. **Build overrides**: Generates material-specific slicer overrides
   (temperature, speed, retraction) for the target material.
4. **Reslice + print**: Reslices the model with new settings and
   starts the print with the correct AMS mapping.

Example: "Reprint my grip extension in PETG"::

    smart_reprint(
        file_name="grip_extension",
        material_id="petg",
        printer_name="my_bambu",
        printer_id="bambu_a1",
    )

The tool will find ``grip_extension.stl`` on disk, detect that PETG
is loaded in AMS slot 1, adjust temps/speeds for PETG, reslice, and
start printing — all in one call.

Saved-goal carry-forward: when the source model on disk has a
``<file>.intent.json`` sidecar tagged with a saved goal, that
goal's id is auto-recovered and surfaced as ``goal_id`` in the
result so downstream ``record_print_outcome`` correctly links the
reprint back to the goal. Pass ``goal_id="..."`` explicitly to
override the sidecar derivation (rare — useful for one-off
re-attributions).

Args:
    file_name: Full or partial file name to search for (e.g.
        ``"grip_extension"`` or ``"grip_extension.stl"``).
        Searched in print history first, then in local directories.
    material_id: Target material (e.g. ``"petg"``, ``"tpu"``).
    printer_name: Registered printer name in fleet.
    printer_id: Printer model ID for profile selection.
    search_dirs: Optional JSON array of extra directories to search
        for the model file (e.g. ``'["/home/user/models"]'``).
    extra_overrides: Optional JSON string of additional slicer
        overrides (e.g. ``'{"fill_density": "30%"}'``).
    auto_ams: If ``True`` (default), check before slicing that a spool
        of the target material is loaded, and refuse
        (``AMS_MATERIAL_NOT_LOADED``) when none is. ``False`` leaves the
        check to the print step.
    goal_id: Optional saved-goal id from ``design_session``.  When
        omitted, the source model's intent sidecar (if any) is read
        and the saved goal's id is derived from its ``generator``
        field — so a reprint of a brief-attached design keeps the
        goal link automatically.  Best-effort: missing kiln-pro or
        missing sidecar silently skips.  The goal then records the
        material its part printed in (``goal_material`` in the reply).
    chosen_by: Who picked this material: ``"person"`` when they named it,
        ``"agent"`` when you proposed it.  Kept with the goal's record;
        omitted, it is left unsaid.
    mixed_nozzle_experiment: The person has said yes, for this print, to a slice refused with
        ``MULTI_NOZZLE_MIXED_SIZES`` (nozzles of different sizes at once, an experiment). Only
        on their yes, each time; ``slice_model`` says what follows.
    soft_nozzle_confirmed: The owner has said to print anyway a slice
        refused with ``ABRASIVE_ON_SOFT_NOZZLE`` (an abrasive filament
        through a nozzle on record that is not wear-resistant).  Only on
        their word, never on your own judgement.
    filament_map: Only for a printer with more than one nozzle: the
        nozzle (1 for the first) each filament prints from, one number
        per filament in filament order.  Leave unset to let the slicer
        choose; a map that does not fit is refused before slicing, as
        ``slice_model`` refuses it.

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": {
      "file_name": "<file_name>",
      "material_id": "<material_id>"
    },
    "name": "smart_reprint"
  }
}

Input Schema

NameRequiredDescriptionDefault
goal_idNoOptional saved-goal id from ``design_session``. When omitted, the source model's intent sidecar (if any) is read and the saved goal's id is derived from its ``generator`` field — so a reprint of a brief-attached design keeps the goal link automatically. Best-effort: missing kiln-pro or missing sidecar silently skips. The goal then records the material its part printed in (``goal_material`` in the reply). Default: "".
auto_amsNoIf ``True`` (default), check before slicing that a spool of the target material is loaded, and refuse (``AMS_MATERIAL_NOT_LOADED``) when none is. ``False`` leaves the check to the print step. Default: true.
chosen_byNoWho picked this material: ``"person"`` when they named it, ``"agent"`` when you proposed it. Kept with the goal's record; omitted, it is left unsaid. Default: "".
file_nameYesFull or partial file name to search for (e.g. ``"grip_extension"`` or ``"grip_extension.stl"``). Searched in print history first, then in local directories.
printer_idNoPrinter model ID for profile selection.
material_idYesTarget material (e.g. ``"petg"``, ``"tpu"``).
search_dirsNoOptional JSON array of extra directories to search for the model file (e.g. ``'["/home/user/models"]'``).
filament_mapNoOnly for a printer with more than one nozzle: the nozzle (1 for the first) each filament prints from, one number per filament in filament order. Leave unset to let the slicer choose; a map that does not fit is refused before slicing, as ``slice_model`` refuses it.
printer_nameNoRegistered printer name in fleet.
extra_overridesNoOptional JSON string of additional slicer overrides (e.g. ``'{"fill_density": "30%"}'``).
soft_nozzle_confirmedNoThe owner has said to print anyway a slice refused with ``ABRASIVE_ON_SOFT_NOZZLE`` (an abrasive filament through a nozzle on record that is not wear-resistant). Only on their word, never on your own judgement. Default: false.
mixed_nozzle_experimentNoThe person has said yes, for this print, to a slice refused with ``MULTI_NOZZLE_MIXED_SIZES`` (nozzles of different sizes at once, an experiment). Only on their yes, each time; ``slice_model`` says what follows. Default: false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv1.6.0
    • changedInput schema / properties / auto_ams / description
      Previous value: -"If ``True`` (default), automatically detect AMS slot for the target material. Set to ``False`` to skip AMS detection (useful for non-Bambu printers). Default: true."New value: +"If ``True`` (default), check before slicing that a spool of the target material is loaded, and refuse (``AMS_MATERIAL_NOT_LOADED``) when none is. ``False`` leaves the check to the print step. Default: true."
    • removedInput schema / properties / brief_id
      Removed value: -{
      -  "description": "Optional saved-goal id from ``design_session``.  When omitted, the source model's intent sidecar (if any) is read and the saved goal's id is derived from its ``generator`` field — so a reprint of a brief-attached design keeps the goal link automatically.  Best-effort: missing kiln-pro or missing sidecar silently skips.  The goal then records the material its part printed in (``goal_material`` in the reply). Default: \"\".",
      -  "title": "Brief Id",
      -  "type": "string"
      -}
    • addedInput schema / properties / filament_map
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "type": "integer"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Only for a printer with more than one nozzle: the nozzle (1 for the first) each filament prints from, one number per filament in filament order.  Leave unset to let the slicer choose; a map that does not fit is refused before slicing, as ``slice_model`` refuses it.",
      +  "title": "Filament Map"
      +}
    • addedInput schema / properties / goal_id
      Added value: +{
      +  "description": "Optional saved-goal id from ``design_session``.  When omitted, the source model's intent sidecar (if any) is read and the saved goal's id is derived from its ``generator`` field — so a reprint of a brief-attached design keeps the goal link automatically.  Best-effort: missing kiln-pro or missing sidecar silently skips.  The goal then records the material its part printed in (``goal_material`` in the reply). Default: \"\".",
      +  "title": "Goal Id",
      +  "type": "string"
      +}
    • addedInput schema / properties / mixed_nozzle_experiment
      Added value: +{
      +  "description": "The person has said yes, for this print, to a slice refused with ``MULTI_NOZZLE_MIXED_SIZES`` (nozzles of different sizes at once, an experiment). Only on their yes, each time; ``slice_model`` says what follows. Default: false.",
      +  "title": "Mixed Nozzle Experiment",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / soft_nozzle_confirmed
      Added value: +{
      +  "description": "The owner has said to print anyway a slice refused with ``ABRASIVE_ON_SOFT_NOZZLE`` (an abrasive filament through a nozzle on record that is not wear-resistant).  Only on their word, never on your own judgement. Default: false.",
      +  "title": "Soft Nozzle Confirmed",
      +  "type": "boolean"
      +}
  2. Changed9 schema fields changedv1.5.1
    • changedInput schema / properties / auto_ams / description
      Previous value: -"Default: true."New value: +"If ``True`` (default), automatically detect AMS slot for the target material. Set to ``False`` to skip AMS detection (useful for non-Bambu printers). Default: true."
    • changedInput schema / properties / brief_id / description
      Previous value: -"Default: \"\"."New value: +"Optional saved-goal id from ``design_session``.  When omitted, the source model's intent sidecar (if any) is read and the saved goal's id is derived from its ``generator`` field — so a reprint of a brief-attached design keeps the goal link automatically.  Best-effort: missing kiln-pro or missing sidecar silently skips.  The goal then records the material its part printed in (``goal_material`` in the reply). Default: \"\"."
    • addedInput schema / properties / chosen_by
      Added value: +{
      +  "description": "Who picked this material: ``\"person\"`` when they named it, ``\"agent\"`` when you proposed it.  Kept with the goal's record; omitted, it is left unsaid. Default: \"\".",
      +  "title": "Chosen By",
      +  "type": "string"
      +}
    • addedInput schema / properties / extra_overrides / description
      Added value: +"Optional JSON string of additional slicer overrides (e.g. ``'{\"fill_density\": \"30%\"}'``)."
    • addedInput schema / properties / file_name / description
      Added value: +"Full or partial file name to search for (e.g. ``\"grip_extension\"`` or ``\"grip_extension.stl\"``). Searched in print history first, then in local directories."
    • addedInput schema / properties / material_id / description
      Added value: +"Target material (e.g. ``\"petg\"``, ``\"tpu\"``)."
    • addedInput schema / properties / printer_id / description
      Added value: +"Printer model ID for profile selection."
    • addedInput schema / properties / printer_name / description
      Added value: +"Registered printer name in fleet."
    • addedInput schema / properties / search_dirs / description
      Added value: +"Optional JSON array of extra directories to search for the model file (e.g. ``'[\"/home/user/models\"]'``)."
  3. Changed10 schema fields changedv1.5.0
    • removedInput schema / properties / auto_ams / default
      Removed value: -true
    • addedInput schema / properties / auto_ams / description
      Added value: +"Default: true."
    • removedInput schema / properties / brief_id / default
      Removed value: -""
    • addedInput schema / properties / brief_id / description
      Added value: +"Default: \"\"."
    • changedInput schema / properties / extra_overrides / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "additionalProperties": true,
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • removedInput schema / properties / extra_overrides / default
      Removed value: -null
    • removedInput schema / properties / printer_id / default
      Removed value: -null
    • removedInput schema / properties / printer_name / default
      Removed value: -null
    • changedInput schema / properties / search_dirs / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • removedInput schema / properties / search_dirs / default
      Removed value: -null
  4. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Beyond the annotations (readOnlyHint=false, destructiveHint=true), it discloses the actual multi-stage side effects: history/file search, AMS tray reads, slicer override generation, reslice, and print start. It also surfaces failure modes by name (AMS_MATERIAL_NOT_LOADED, MULTI_NOZZLE_MIXED_SIZES, ABRASIVE_ON_SOFT_NOZZLE) and the best-effort sidecar lookup. A 5 would require more on what happens if printing cannot start or how the job can be aborted, but the side-effect profile is unusually well disclosed.

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

Conciseness3/5

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

The numbered pipeline and the front-loaded one-line summary are well ordered and the example earns its place. However, the full Args section duplicates a schema that already has 100% description coverage, and the goal_id / mixed_nozzle_experiment / soft_nozzle_confirmed explanations are verbose and repeated across both description and schema.

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 12-parameter, multi-stage tool with no output schema, it names result fields (goal_id, goal_material) and explains the sidecar recovery, which is genuinely helpful. The notable gap is that printer_name and printer_id are optional with no explanation of how the target printer is resolved when they are omitted — a real ambiguity for a destructive print-starting tool.

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%, and the description's Args block restates the schema field descriptions nearly verbatim rather than adding meaning (e.g. search_dirs, extra_overrides, printer_name are identical). The example call does clarify the intended combination of printer_name and printer_id, which the schema alone leaves ambiguous, but that is the main value-add over structured data.

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 states a specific verb+resource with scope ('Smart one-shot material-switch reprint — finds the model, detects the right AMS slot, adjusts slicer settings, and prints'), and it explicitly positions itself as 'the highest-level reprinting tool', which distinguishes it from lower-level siblings like reprint_with_material and slice_model.

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 states the inputs that trigger the one-shot flow ('Give it a file name (or partial name) and a target material, and it handles everything') and frames itself as the top-level option versus slice_model, which it names for refusal cases. What's missing is an explicit when-NOT-to-use condition — e.g. when to call slice_model or reprint_with_material directly instead — so the routing is implied rather than stated.

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