Skip to main content
Glama

Sheet Refold

sheet_refold

Verify a sheet metal flat pattern by refolding it and comparing the result to the original part, catching errors in bend allowances, angles, or directions.

Instructions

Fold a flat pattern back up and check it reproduces the part — the other half of the unfold gate.

This does NOT replay the feature model. It reads the flat pattern back: each leg length is measured off the flat outline, walking outward from the bend's attachment past its reported bend allowance to the far edge of that region. So a wrong allowance, angle or bend direction lands the refolded solid somewhere the original is not, and this reports the disagreement instead of hiding it.

handle: a sheet part to unfold and then refold. flat: alternatively a sheet_unfold report, to refold a development produced elsewhere (or a deliberately corrupted one, to prove the check bites). compare: the handle to check against; defaults to handle, and is skipped when only flat is given. volume_tol_pct / bbox_tol_mm: agreement tolerances.

Note the round trip that is meaningful and the one that is not: refold-vs-folded must match, but flat-vs-folded VOLUME must not, and does not. Bending preserves neutral-fibre length, not material volume — a bend sector's true volume is angle·t·(R + t/2)·w while its flat footprint is angle·(R + K·t)·t·w, and those agree only at K = 0.5.

Returns {handle, name, volume_mm3, bbox, bends, compare?} where compare is {handle, matches, volume_mm3, volume_error_pct, bbox_max_error_mm, tolerance}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
flatNo
nameNoSheetRefold
handleNo
compareNo
k_factorNo
bend_tableNo
bbox_tol_mmNo
volume_tol_pctNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations do not promise read-only behavior, so the prose carries the burden of explaining what happens; it fills this gap with concrete mechanics: each leg length is measured off the flat outline, walking outward past the reported bend allowance, and disagreement is reported rather than hidden. It also discloses the important fact that the feature model is not replayed and explains why volume differences are expected.

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 description front-loads a clear one-sentence purpose, then provides algorithmic detail and a cautionary note. The volume math is verbose but directly prevents a likely misinterpretation, so it earns its place. It is longer than minimal but well organized.

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?

The return shape is explicitly listed even though no output schema exists, and the meaningful versus non-meaningful round trips are covered. However, three parameters are undocumented in prose, and there is no guidance about error conditions or invalid inputs. For a complex sheet-metal verification tool, this is adequate but not complete.

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 0%, so the description must compensate; it explains handle, flat, compare, and the two tolerance parameters well. However, name, k_factor, and bend_table appear only in the schema with no prose explanation of their meaning or effect. This leaves a significant gap for a tool with eight optional parameters.

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 opening sentence states a specific verb/resource pair ('Fold a flat pattern back up and check it reproduces the part') and frames the tool as the counterpart to the unfold gate. The description also distinguishes it from feature-model replay by explicitly saying 'does NOT replay the feature model,' making its identity clear among sheet-metal siblings.

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?

The description explains when the check is meaningful ('refold-vs-folded must match') and explicitly warns that flat-vs-folded volume must not match, which prevents a common misuse. It also describes alternative valid inputs, such as passing a sheet_unfold report to test a corrupted development. It does not name sibling tools as alternatives, but the guidance is sufficient.

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