Skip to main content
Glama

edit_params

Change named parameters in a script mesh2cad generated and re-render the solid.

Instructions

Change named parameters in a script mesh2cad generated and re-render the solid.

Args: script_path: path to a .py, .scad, or .FCMacro file written by mesh2cad. changes: mapping of parameter name to a new number, or to a string that starts with + or - to add that delta (for example {"hole_1_d": 8, "base_x": "+2"}). output_path: STEP or STL to write. CadQuery and FreeCAD accept .step or .stl. OpenSCAD accepts .stl. When omitted, a .step (or .stl for OpenSCAD) is written next to the script if that backend is available. The script is updated in place. Every byte outside the replaced numbers stays the same. Unknown names are refused with the valid list. An edit that does not produce one valid solid, or a hole larger than the wall it sits in, is refused and nothing is written. Returns old and new values, the rendered path, validity, volume and bounding-box delta, and warnings. Returns an "error" key when the edit is refused or the backend needed for output_path is not available.

Input Schema

NameRequiredDescriptionDefault
changesYes
output_pathNo
script_pathYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.19.0

TDQS

A4.3/5.0
Behavior5/5

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

With no annotations supplied, the description carries the full behavioral burden and does so thoroughly: in-place mutation, byte-level preservation outside replaced numbers, refusal on invalid solid or oversized hole with nothing written, and an 'error' key when the backend is missing. These are exactly the side-effect and failure semantics an agent needs before invoking a mutating tool.

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 core action is front-loaded in one sentence, then a compact Args block, then behavior. The Args section partly restates the schema, but each line adds format or constraint detail, so little is 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?

Despite no output schema and a nested free-form 'changes' object, the description states the return payload (old/new values, rendered path, validity, volume, bbox delta, warnings) and the error case. Nothing material is missing for correct invocation of a destructive-adjacent edit tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, and it does: script_path file-type restrictions (.py/.scad/.FCMacro), the changes mapping with number vs. '+2'/'-' delta string syntax and a concrete example, and output_path format rules per backend plus the default when omitted. This adds substantial meaning beyond the bare schema types.

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?

The description opens with a specific verb+resource pair ('Change named parameters in a script mesh2cad generated') and adds the consequential second action ('re-render the solid'). It is clearly distinguishable from read-only siblings like list_params and analyze, though it never names a sibling explicitly.

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?

Usage is implied rather than stated: the refusal of unknown names 'with the valid list' hints that list_params should be consulted first, and the output_path rules signal when each backend applies. There is no explicit when-to-use / when-not-to-use statement or named alternative.

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