Skip to main content
Glama

counterpart_part_meshes

Counterpart contract (counterpart/1): one STL per printable part of any 3MF (a pass's, counterpart_make_3mf's, cad_run's project_3mf, or a designer's Bambu Studio, OrcaSlicer or plain 3MF), so a client draws each part in its colour or…

Instructions

Counterpart contract (counterpart/1): one STL per printable part of any 3MF (a pass's, counterpart_make_3mf's, cad_run's project_3mf, or a designer's Bambu Studio, OrcaSlicer or plain 3MF), so a client draws each part in its colour or shows the design in AR. Writes into a new folder it creates inside out_dir and never overwrites. Returns units (mm), folder and parts: [{id, name, plate?, color?, filament?, painted?, stl_path, triangles, size_mm}], one per part per printed copy. Every STL is in the 3MF's build frame in millimetres, component and build transforms applied, so the parts line up when drawn together; plate is the plate number from 1 (list_3mf_plates index + 1), absent for a 3MF without plates; color is #RRGGBB from the 3MF's own filament colours, absent when it declares none; painted means slicer painting recolours some facets. A part beyond the read limits is listed in skipped with why.

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": {
      "three_mf_path": "<three_mf_path>",
      "out_dir": "<out_dir>"
    },
    "name": "counterpart_part_meshes"
  }
}

Input Schema

NameRequiredDescriptionDefault
out_dirYesAn existing folder; each call writes into a new subfolder of it.
three_mf_pathYesPath to the 3MF.

Output Schema

NameRequiredDescriptionDefault
partsYes
unitsYes
folderYesThe new folder the STLs were written in.
skippedNo
contractYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.1.97

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=false) by disclosing that it creates a new subfolder inside out_dir and never overwrites — consistent with a non-destructive, non-idempotent write. It also discloses coordinate semantics (build frame, millimetres, transforms applied), read limits, and a 'skipped with why' escape hatch, which is exactly the operational context annotations cannot carry.

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 information is valuable but packed into a few very long, semicolon-chained sentences with no paragraph or bullet structure, and it restates the full return record field list despite an output schema existing. Front-loading is decent, yet the density makes it harder to scan than it needs to be.

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 file-writing extraction tool, the definition covers units, coordinate frame, plate numbering convention, colour provenance, painted-facet semantics, and overflow handling via 'skipped' — nothing an agent needs to call it correctly is missing.

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 coverage is 100% and the two parameters are already documented in the schema (including that out_dir is an existing folder and gets a new subfolder per call), so the description adds little about parameters themselves. Its detail is instead about output geometry and units, which is useful but not parameter semantics.

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?

States a concrete resource and output shape: 'one STL per printable part of any 3MF', and enumerates accepted sources (a pass's, counterpart_make_3mf's, cad_run's project_3mf, Bambu Studio/OrcaSlicer/plain 3MF). An agent can tell this apart from counterpart_make_3mf (which produces a 3MF) and from list_3mf_plates without opening any 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?

Gives the motivating use cases ('so a client draws each part in its colour or shows the design in AR') and implies when a 3MF needs splitting, but names no alternatives and no when-not conditions. A reader knows why to call it, yet is not routed away from any sibling.

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