Skip to main content
Glama
pzfreo

build123d-mcp

save_drawing_annotations

Save drawing annotation metadata to a sidecar .dims.json file so label strings from build123d dimensions and leaders can be restored when inspecting an SVG later.

Instructions

DEPRECATED (#465) — moved to draftwright; off by default in 0.4.0, removed in 0.5.0. Calling it explains the replacement. Write a .dims.json sidecar file alongside an SVG with label metadata.

build123d renders Text as filled glyph paths, not <text> SVG elements, so
label strings are irrecoverable from a finished SVG. Call this tool after
completing a drawing (annotate all dims/leaders with annotate()) and before
or after exporting the SVG. The sidecar is read automatically by
inspect_drawing(svg_path=...) to restore annotation content.

Workflow:
    1. Build your drawing with Dimension / Leader / annotate()
    2. Export SVG:  execute("exporter.write('drawing.svg')")
    3. Save metadata: save_drawing_annotations("drawing.svg")
    4. Inspect later: inspect_drawing(svg_path="drawing.svg")
       → includes full annotations dict from the sidecar

Args:
    svg_path: path to the SVG file (sidecar written as <svg_path>.dims.json).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
svg_pathYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.3.27

TDQS

A4.8/5.0
Behavior4/5

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

Annotations only set readOnlyHint=false and destructiveHint=false, so the description carries the burden of explaining write behavior. It does so well: writes a sidecar, explains why it is necessary (build123d renders text as glyph paths, making labels irrecoverable), and notes the sidecar is automatically read by inspect_drawing. It stops short of stating overwrite behavior or error cases, but the core behavioral context is strong.

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

Conciseness5/5

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

The description is longer than minimal but every sentence earns its place: deprecation status, why the sidecar is needed, when to call, the workflow, and parameter detail. It is front-loaded with the deprecation warning and structured with a numbered workflow and args section, making it easy for an agent to parse.

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 single-parameter tool with an output schema, this description is complete. It covers deprecation, the exact calling sequence relative to export, the sidecar file naming, and integration with inspect_drawing. An agent has everything it needs to decide whether to use the tool and how to invoke it correctly.

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 entirely for the single parameter. It does, fully: 'svg_path: path to the SVG file (sidecar written as <svg_path>.dims.json).' This adds the sidecar naming convention and makes the parameter semantics unambiguous. No other parameters exist to document.

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 specific verb and resource: 'Write a .dims.json sidecar file alongside an SVG with label metadata.' This clearly distinguishes it from sibling tools like export (which writes the SVG), inspect_drawing (which reads the sidecar), and lint_drawing. The deprecation note also clarifies its legacy status without muddling purpose.

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?

Explicitly says when to call it: 'after completing a drawing (annotate all dims/leaders with annotate()) and before or after exporting the SVG.' Provides a numbered workflow with exact call order and names the consumer (inspect_drawing). Also gives an exclusion: deprecated and moved to draftwright, so agents know not to rely on it going forward.

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