Skip to main content
Glama
b123d-print-mcp

b123d-print-mcp

by KD5RYN

new_part

Scaffold a new build123d part script from a template, with dimensions, build function, variants, views, and checks; use it to start a part before writing the full model script.

Instructions

Create parts//.py from the template (Dims dataclass, build(d), VARIANTS, views, checks). name: lower_snake_case. example: copy a bundled example instead (see list_parts), e.g. 'hole_coupon' to calibrate hole compensation. sketch_first: the template with a sketches(d) outline that build(d) extrudes, for a part that is mostly a 2D shape made solid (offer it per part, see the guide's Sketch first); check the outline with render_sketch. Returns a short confirmation; the template is the b123d-print://template resource (or read_part), show_code=True returns the new file's code here. Usually the next step is write_part with the whole script. If you haven't, call read_guide first; confirm the dimensions with the user before writing the script.

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": {
      "name": "<name>"
    },
    "name": "new_part"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYes
exampleNo
show_codeNo
descriptionNo
sketch_firstNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.17
    • addedInput schema / properties / sketch_first
      Added value: +{
      +  "default": false,
      +  "title": "Sketch First",
      +  "type": "boolean"
      +}
  2. First observedv0.3.12

TDQS

A4.6/5.0
Behavior4/5

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

With no annotations, the description does real work: it names the file path created, says the return is a short confirmation, that show_code=True echoes the new file's code instead, and that the template lives at the b123d-print://template resource or via read_part. It stops short of stating what happens if parts/<name>/<name>.py already exists (overwrite vs. error), which is the key remaining risk for a create 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?

Front-loaded with the core action and file path, then parameter semantics, then return/next-step guidance. It is dense and parenthetical-heavy but nearly every clause carries information; the nested asides ('see the guide's Sketch first') slightly dilute scanability.

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 5-param creation tool with no annotations, the description covers prerequisites (read_guide, user confirmation), mode selection, return shape, and the follow-on call (write_part). An output schema exists, and the description still clarifies that the template is retrievable separately, so an agent has everything needed to invoke it correctly.

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

Parameters4/5

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

Schema coverage is 0%, so the description must compensate, and it largely does: `name` gains a lower_snake_case constraint, `example` gains meaning (bundled example selector, cross-referenced to list_parts with a concrete value), and `sketch_first` and `show_code` are both explained behaviorally. The fifth parameter, `description`, is never mentioned anywhere, leaving one gap.

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 verb and artifact: 'Create parts/<name>/<name>.py from the template', and even enumerates what the template contains (Dims dataclass, build(d), VARIANTS, views, checks). This is clearly distinguishable from write_part, read_part, and make_template in the sibling list.

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?

Routes the agent explicitly: use `example` to copy a bundled example instead (pointing at list_parts and naming 'hole_coupon'), use `sketch_first` for mostly-2D parts and verify via render_sketch, call read_guide first, confirm dimensions with the user, and the usual next step is write_part. When-to-use, alternatives, and prerequisites are all stated.

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