Skip to main content
Glama
geongyeelee

autocad-mcp

by geongyeelee

inspect_or_create_dxf

Inspect an existing DXF for layer and entity summaries, or create a new DXF from entity specifications, with an option to open the result in AutoCAD.

Instructions

High-speed offline DXF inspection or creation using ezdxf, with optional handoff to AutoCAD 2027.

Args: dxf_path: Path to the .dxf file to inspect or create. action: 'inspect' to read layers/entities summary of an existing DXF, or 'create' to generate a new DXF from entities_spec. entities_spec: For action='create', a list of dicts describing entities, e.g. [{'type': 'LINE', 'start': [0,0], 'end': [100,0], 'layer': 'WALL'}, {'type': 'CIRCLE', 'center': [50,50], 'radius': 20}]. open_in_autocad: If True, opens the DXF file in the AutoCAD 2027 GUI after completion.

Input Schema

NameRequiredDescriptionDefault
actionNoinspect
dxf_pathYes
entities_specNo
open_in_autocadNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/5.0
Behavior3/5

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

No annotations, so the description carries the full burden. It discloses useful traits — offline/high-speed, ezdxf backend, GUI handoff via open_in_autocad — but never says whether 'create' overwrites an existing file at dxf_path, whether the path must already exist for 'inspect', or what happens on failure. For a tool that writes files, the overwrite semantics are a real gap.

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 summary sentence is front-loaded and carries the key framing; the args block is compact and each entry earns its place. The entities_spec example is verbose but justified given zero schema documentation.

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?

An output schema exists, so return values need not be explained. However, for a file-writing tool with no annotations, the description leaves out overwrite behavior, path-existence requirements, and error/validation semantics — the remaining gaps an agent needs before calling 'create' safely.

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: all four params are documented, with concrete example entity dicts showing required keys for LINE and CIRCLE. It stops short of enumerating valid entity types or the per-type required keys, so an agent must guess beyond the two examples.

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?

States a specific verb+resource pair ('DXF inspection or creation') plus the engine used (ezdxf) and the optional AutoCAD 2027 handoff. This implicitly separates it from the live-drawing siblings like draw_line/query_entities, though no sibling is named explicitly.

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 action parameter is disambiguated with explicit conditions: 'inspect' for reading layers/entities of an existing DXF, 'create' for generating from entities_spec. Missing is any guidance on when to choose this offline tool over the live AutoCAD siblings (draw_*, query_entities).

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