AutoCAD MCP Pro
Enables AI agents to automate AutoCAD through live COM control on Windows or headless DXF via ezdxf, providing tools for drawing, editing, dimensioning, managing layers and blocks, generating P&IDs, mechanical and architectural plans, reading drawings, and producing takeoffs and schedules.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@AutoCAD MCP ProCreate a floor plan with walls, doors, and measured room areas"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
AutoCAD MCP Pro
Production-grade AutoCAD automation for AI agents. Live through COM on Windows, or headless through ezdxf anywhere — one typed contract, two engines.
Install · What's new · Tools · Engines · Evidence · Limits · Config · Changelog
Not a mockup. Every line on this sheet was drawn by the tools this server exposes — ISO layers, involute gear geometry, DIN 6885 keyway, section A-A, ISO 129 dimensions, an ISO 286 H7 bore fit, ISO 7200 title block — then rendered headlessly by view_screenshot. drawing_critique returns 0 issues on it. Rebuild it with python scripts/render_readme_showcase.py.
v1.6 release snapshot: 247 tools · 8 resources · 5 prompt templates · 5013 collected tests. 247 is the registered count; a default install advertises 242 over
tools/list, becauseENABLE_3Dis unset.system_aboutis the runtime authority.
What's new in 1.6
Five tracks of one roadmap, 154 → 247 registered tools. Each track has its own design spec, correctness checks that can fail, and a live AutoCAD 2026 run of its COM paths recorded in the changelog.
Track | What it adds | Pack |
P&ID — drafter and reader | 43 ISO 10628-2 / ISA-5.1 symbols as real blocks with ports and |
|
The AutoCAD environment | ISO-25 / ANSI dimension styles, text and leader styles, |
|
Mechanical parts and the sheet | one part model and one view engine (front, side, top, section and detail views with hidden lines, cut faces and ISO 129 dimensions), ISO fasteners and bearings as blocks with attributes, ISO 21920-1 surface texture, ISO 2553 welds, ISO 5457 frames A4–A0, ISO 7200 title blocks, an ISO 7573 parts list read off the drawing with linked ISO 6433 balloons, xrefs, images, real |
|
Architecture | walls with hosted doors and windows: one engine resolves L / T / X junctions and cuts the openings. Room areas are measured from the faces the walls enclose, and rooms are read back from any plan. Door / window / room schedules are real tables; labels in English or Turkish |
|
Understanding and takeoffs |
|
|
TOOL_PACKS keeps a client from paying for the tracks it does not use (idle cost below).
A mechanical sheet, gated. The mech_assembly benchmark sheet: a hub drawn from its part model with a full section and chain dimensions, a flange with its bolt-circle end view, two ISO 4014 M12×60 bolts and ISO 4032 nuts inserted as blocks, the ISO 7573 parts list read off the drawing, balloons linked to its rows, an ISO 5457 frame and an ISO 7200 title block. drawing_critique(focus=None) returns 0 issues and the finalize score is 100. Rebuild it with python scripts/render_readme_mech.py.
A floor plan whose areas nobody typed. arch_plan_from_spec's example, drawn in one transaction: a 250 mm brick ring split by a 100 mm AAC wall, two doors, two windows, a straight stair and exterior dimension chains at 1:50. The rooms measure 27.74 and 21.99 m², read from the faces the walls enclose, and the door, window and room schedules are read off the drawing. drawing_critique(focus=None) returns 0 issues. Rebuild it with python scripts/render_readme_arch.py.
The same server as a P&ID drafter. pid_from_spec placed five catalogue symbols as real blocks with TAG attributes and named ports and routed four port-to-port lines with ISA-5.1 classes and line numbers, all in one transaction. Then pid_graph read the sheet back: 5 nodes, 4 edges, 0 dangling ends, confidence_min 1.0. Rebuild it with python scripts/render_readme_pid.py.
The catalogue, authored in code. 43 ISO 10628-2 / ISA-5.1 symbols: 11 valve bodies × 6 actuators, 6 rotating machines, 4 heat exchangers, 6 parametric vessels, 7 inline items, the instrument bubble in 4 types × 5 locations, 5 line markers and 3 connectors. Every one was placed through pid_symbol_insert's own path. Rebuild it with python scripts/render_pid_catalog.py.
Related MCP server: AutoCAD MCP Pro
Why this exists
A big MCP server is expensive to be connected to. The full catalog costs a client 83,921 tokens before it has asked for anything. Discovery mode replaces it with two tools and costs 356.
A drafter searches for FILLET, not entity_fillet. Before the corpus, those command names appeared in no tool name or description. That was df = 0 against a stock index: the tools were not ranked badly, they were absent. The fix was data: an authored corpus of 206 AutoCAD command names and 1439 synonym phrases covering all 247 tools. A test refuses to let a tool exist without one.
Advertised surface | Tools seen | Idle cost |
| 242 | 83,921 tokens |
| 205 | 63,890 tokens |
| 197 | 64,836 tokens |
| 195 | 63,549 tokens |
| 192 | 60,844 tokens |
| 185 | 59,290 tokens |
| 183 | 57,122 tokens |
| 65 | 22,661 tokens |
| 2 | 356 tokens |
These are offline ratio estimates, not tokenizer counts, and they are theuncached cost: prompt caching amortises the idle term. benchmarks/token_suite.py --tokenizer anthropic counts for real.
Install
pip install autocad-mcp-pro # or: uvx autocad-mcp-pro
autocad-mcp # stdio MCP server, backend auto-selectedAUTOCAD_MCP_BACKEND=ezdxf autocad-mcp # portable DXF engine, no AutoCAD needed
AUTOCAD_MCP_BACKEND=com autocad-mcp # live AutoCAD (needs the [com] extra)Extra | Pulls in | For |
(none) |
| Headless DXF on any OS — no rendering |
|
| Live AutoCAD control + window capture |
|
| PDF export and headless PNG, any platform |
|
| XLSX workbooks (takeoffs, |
| everything above | Development and CI |
The bare installcannot draw pixels — ezdxf.addons.drawing imports Pillow unconditionally, so every render path needs it. Add [pdf] for images on Linux or macOS.
{
"mcpServers": {
"autocad": {
"command": "autocad-mcp",
"env": {
"AUTOCAD_MCP_BACKEND": "auto",
"ALLOWED_PATHS": "C:\\Users\\you\\Documents\\AutoCAD",
"TOOL_PROFILE": "full",
"TOOL_PACKS": "all",
"DISCOVERY_MODE": "off"
}
}
}
}It works with Claude Desktop, Cursor, or any stdio MCP host. For HTTP, run autocad-mcp --transport http --port 8000. It binds loopback only, unless remote HTTP is explicitly enabled and a bearer token is set.
What you get
Area | What it does |
Drawing lifecycle | create, open, save, export DXF/PDF, audit (repairs), purge, undo/redo |
Geometry | lines, arcs, polylines, splines, hatches, trim/extend/fillet/chamfer, handle-preserving edits |
Annotation | ISO 129 toleranced dimensions, ISO 286 fits ( |
Engineering generators | involute gears (front + section A-A), DIN 6885 keyed bores, ISO A3 title block |
Mechanical parts | one part model (segments or outline + typed features) and one view engine: front / side / top / section / detail with hidden lines, ISO 128-50 cut faces and ISO 129 dimensions. ISO 4014/4017/4032/7089/4762 fasteners and ISO 15 bearings insert as real blocks with attributes. DIN 471/472, DIN 509, DIN 332 and ISO 3601-2 features have their drawing code, but their tables ship empty in 1.6 (see limits). Also ISO 21920-1 surface texture, ISO 2553 welds and ISO 128-40 section lines |
Sheet & delivery | ISO 5457 frames A4-A0 with zones and trim marks, ISO 7200 title blocks for every size, revision blocks with clouds, ISO 7573 parts lists with ISO 6433 balloons linked by XDATA, CSV/XLSX extraction, xrefs and images on both engines, real |
Architecture | one plan model (walls with hosted doors and windows) and one engine that resolves L / T / X junctions, cuts openings and draws poché by material. Room areas are measured from the faces the walls enclose, never typed, and rooms are read back from any plan with a confidence. Door / window / room schedules are real TABLEs. Also a furniture and sanitary catalogue at nominal sizes, a structural grid, north arrow, section / level / elevation marks, exterior dimension chains, and English or Turkish labels ( |
Understanding & takeoffs |
|
P&ID | catalogue blocks with ports and tags (ISO 10628-2 / ISA-5.1), port-to-port lines with ISA-5.1 classes and line numbers, |
Styles & standards | ISO-25 / ANSI dimension styles, ISOCP / ROMANS text styles, ISO / ANSI leader styles from authored presets; |
Discovery |
|
Batching |
|
Paper space | tab lifecycle, viewports, |
Page setup & templates | ISO 216 / ANSI Y14.1 sheets, ctb catalog, |
Environment | several open documents headlessly, portable layer states ( |
Selection | window vs crossing stated back to the caller; a polygon tested against its own shape, not its bounding box |
Boundaries |
|
Measurement |
|
Hatch depth | gradients, in-place edits, typed edge boundaries (headless), island styles |
Annotation objects | WIPEOUT, REVCLOUD, MTEXT background masks (headless), text find/replace |
3D solids |
|
Quality loop |
|
Delivery |
|
247 tools in 28 groups. TOOL_PACKS=core hides these from a client that needs none of them: the nine pid_* tools, the 22 environment tools, the 14 mechanical tools, the 12 architectural tools and the two plant takeoffs. TOOL_PACKS=core,mech keeps the mechanical ones, TOOL_PACKS=core,arch the architectural ones, and TOOL_PACKS=core,plant the takeoffs. There are also 8 resources that cost nothing in the tool budget (autocad://drawing/info, layers, blocks, entities/stats, entities/{layer_name}, system/status, pid/symbols, standards/isa51) and 5 prompt templates.
Two rules worth knowing.
Every coordinate in and out of a tool is WCS on both engines. The one exception is TEXT
rotation, which stays in the entity frame: a mirrored TEXT is mirror-imaged, and no scalar angle expresses that.Never read vertices back and shoelace them. That silently loses 28.2% of the area on a semicircular edge.
analysis_measure_entity(handle)reads the real geometry and states its own accuracy.
The two engines
One contract across 23 modules in backends/contracts/. @capability(key, reason=…) supplies a default that refuses, and a test holds both backends' capability key sets equal. There are 41 capability keys. Read system_capabilities at runtime rather than trusting the table: several depend on what the machine has installed (matplotlib, openpyxl, the ODA File Converter).
Capability | COM (live AutoCAD) | ezdxf (headless) |
Live document control | ✅ | — |
Cross-platform, no AutoCAD | — | ✅ |
Transactions and rollback | ✅ | ✅ |
Paper-space layouts + viewports | ✅ | ✅ |
Viewport model-content rendering | ✅ | ✅ ᵐ (no borders) |
Selection window / crossing / polygon | ✅ | ✅ |
Entity area by handle | ActiveX | Analytic, bulges included |
HATCH filled area (islands subtracted) | AutoCAD's own number | Loops walked, |
REGION / 3DSOLID area | ✅ | — ACIS is opaque to ezdxf |
3D solids | ✅ with | — |
DWG write | ✅ | via the ODA File Converter, if installed |
| ✅ | DXF only — |
Reading a foreign drawing ( | ✅ one | ✅ |
XLSX workbooks | ✅ ᵒ | ✅ ᵒ |
Preferences · launch · operator prompts | ✅ | — refused by name |
WIPEOUT · MTEXT background colour | — verified absent, AutoCAD 2026 | ✅ |
REVCLOUD · BPOLY · typed hatch edges | — no ActiveX member | ✅ |
CHSPACE | — unverified on a live seat | ✅ ᶜ |
Undo history | ✅ | opt-in — |
TABLE and MLEADER | Native | Portable composite |
Screenshots and PDF | Window capture | Matplotlib ᵐ |
ᵐ Needs matplotlib ([pdf]/[full]). Without it, png, pdf, viewport_render and handle_overlay report unsupported headlessly. ᵒ Needs openpyxl ([office]/[full]). Without it, XLSX is refused with xlsx_write and CSV is still written. ᶜ Headless CHSPACE has four restrictions, named in its capability reason: top-view untwisted viewports only; dimensions refused unless frozen; ACIS, proxy and table entities refused; viewport clipping reported rather than applied.
Every COM path added in v1.6 was executed against alive AutoCAD 2026, one smoke script per track (scripts/smoke_*_com.py), each run recorded in the changelog. Those runs found defects no headless test could. ActiveX refuses entity.Layer on a missing layer, where ezdxf quietly creates it, so mech_part_draw died after drawing every view. ActiveX calls a block reference BLOCKREFERENCE, not INSERT, so the parts list read nothing. And once pywin32's type-library cache existed, every listed entity arrived as a bare IAcadEntity with no line endpoints, so the room reader saw no walls and arch_plan_from_spec refused its first room label.
Evidence
Everything below is produced by scripts in benchmarks/ and published as JSON under benchmarks/results/published/.
Against the other AutoCAD MCP servers
A fixed 100-point rubric applied to nine public AutoCAD MCP servers (source_review.json). Stars and raw tool counts score nothing. 1.6.0 is scored per category, with the evidence for every point withheld:
Category | Weight | 1.6.0 | Points withheld for |
Functional CAD coverage | 25 | 24 | no electrical schematics, image-to-CAD tracing, Plant 3D, obstacle-avoiding routing or headless REGION / 3DSOLID |
Correctness and delivery | 20 | 19 | a headless DIMENSION does not re-render; a takeoff on a real P&ID still needs the engineer's scope decisions |
Backends and platforms | 15 | 14 | BricsCAD, ZWCAD and GstarCAD unverified |
Engineering production | 15 | 14 | four DIN / ISO feature tables ship empty |
Tests and maintenance | 15 | 14 | headless entity creation slower than v1.4.0 |
Security and operations | 10 | 8 |
|
Total | 100 | 93 |
Read this as a documented self-assessment, not an independent review: this repository applies the rubric to itself and to the others. The competitor rows are their July 2026 snapshots and were not re-reviewed for this release, and the best of them, varavista/autocad-mcp, scored 84. 1.4.0 was given one overall 95. This review is stricter and scores each category apart.
A second lane runs tasks instead of reading source. Every task in the fixed-task matrix can fail, and its artifacts are verified by re-opening the DXF, never by trusting a response. The reference adapter passes 21 / 21 of matrix v7. The two competitors with adapters, pinned at their July 2026 commits, passed 5 / 10 and 4 / 10 of the ten v2 tasks they were run on. The eleven tasks added since then were never put to them, so they show as not run, not as zero:
Correctness — every release re-proves itself
48 deterministic headless checks against the previous tag and the current tree. Each runs in its own subprocess, so a hard crash counts as a miss rather than killing the run.
Version | Checks passing | Pass rate | Fixed | Regressed |
v1.5.1 (baseline) | 26 / 48 | 54.2 % | — | — |
v1.6.0 (this release) | 48 / 48 | 100 % | 22 | 0 |
The 26 checks v1.5.1 was released on all still pass. The twenty-two fixed rows are new capability (miss → pass), and each one pins a number computed by hand, not read back from the code that drew it:
Track | Check | Verified against |
Understanding |
| the synthetic P&ID reads schematic against its layout; a uniform 2× copy of six tags reads to scale with factor 2 |
| all eight routable runs measure exactly the rectilinear MST of their tags | |
| 9, 17, 19 and 10 m after the 20 % allowance; the heater's unstated power stays empty | |
| a move, a text change, an attribute change, an add and a delete, and nothing else | |
| a 5 mm near miss, one interior crossing, and a clean T that is neither | |
Architecture |
| an L corner mitres at (4100, −100) / (3900, 100), a T stem stops on the near face, an X cuts all four faces; wall areas 1 400 000, 1 490 000 and 2 360 000 mm² |
| a 4 × 5 m room between 200 mm walls is labelled 20.00 m², not the 21.84 m² its axes enclose | |
| both faces are interrupted across a 900 door and two jambs close it | |
| plain lines on a | |
Mechanical and sheet |
| a part read back out of its own |
| a 60 × ⌀40 sleeve with a ⌀20 bore cuts 1200 mm², measured out of the drawing by | |
| 40 H7 is +0.025 / 0 and survives the layout | |
| the ISO 6410 focus fires on a thread drawn as a plain circle. A gate that never fires is not a gate | |
| s = 18, k = 7.5, read by value | |
| the frame runs 20,10 to 410,287 inside the 420 × 297 sheet | |
| two identical bolts are one row of quantity 2, and its balloon carries the row's item number | |
Environment |
| the ISO-25 preset lands in the DIMSTYLE table with ISO 129-1's numbers |
| save → change → restore puts the layer table back, and the state survives save/reopen | |
| the plotted PDF's own | |
P&ID |
| a block with ATTDEFs defined and read back, an ISA-5.1 tag parsed, a drawn P&ID's edge count |
The task matrix — tasks that can fail
An earlier matrix scored this server 10/10, which carried no information: every task in it exercised something the server was built around. Five tasks were added in 1.5 because they can fail, and three of them did while being written. 1.6 adds six more:
one the P&ID reader can fail on its own;
one where the PDF file, not the setter, is the witness;
one where a whole mechanical sheet has to come out clean;
one where a floor plan's rooms are read back off the drawing;
two where a foreign plant's P&ID and layout are read: the takeoffs against lengths computed in advance, and the one-call report against the defects planted in it.
Task | Verified against |
| six AutoCAD command names, each ranking #1 |
| 83,921 → 356 tokens, against a ceiling fixed in advance |
| 300 filled with the island, 400 ignoring it |
| window 1, crossing 2, bounding box 3, polygon 1 |
| 139.2699 against the 100.0 a vertex shoelace gives |
| the example sheet drawn by |
| ANSI B, then ISO A3 landscape, applied to Layout1. Each is plotted through |
| a flange-coupling A3 sheet: a hub with a full section, a flange with its bolt-circle end view, two ISO 4014 bolts with ISO 4032 nuts, an ISO 7573 parts list read off the drawing, linked balloons, an ISO 5457 frame and an ISO 7200 title block. Gated on |
| a two-room plan (an entrance door, an interior door, two windows, a stair) drawn by |
| the synthetic plant pair: a P&ID stretched 1.3× in one room and rearranged in the other, Russian supply / return words, a return drawn on the supply layer, a reducer, a segment drawn twice. The scale check must call it schematic (21.8 % of 55 pairs within ±10 %). |
| the pair's layout (inches declared over millimetres, a stray line 5,000 km out, two plan copies) comes back as millimetres with an |
Headless performance
The workloads call the same backend methods the MCP tools call, so server-side overhead is included. Numbers move with hardware; the report records the machine fingerprint. Read the next section before quoting them. This release is slower than v1.4.0 at creating entities.
What this release is bad at
A page that only lists strengths is a page that has not been measured.
Headless entity creation is slower than v1.4.0, and 1.6 did not win it back. These are medians of five alternating runs on one machine, with one interpreter (CPython 3.11.15) and one ezdxf, v1.4.0's code against 1.6.0's (perf-v1.4.0-vs-v1.6.0.json):
Workload | v1.4.0 | v1.6.0 | v1.6.0, |
2,000 lines, one call each | 244.5 ms | 306.1 ms (1.25×) | 284.9 ms (1.17×) |
10,000 lines: build, DXF export, reopen | 1,847.9 ms | 2,553.5 ms (1.38×) | 2,216.4 ms (1.20×) |
Region query over 10,000 entities | 665.2 ms | 712.2 ms (1.07×) | 783.9 ms (1.18×) |
Premium quality pass | 150.6 ms | 65.3 ms (2.3× faster) | 69.9 ms |
The per-call timeout stops one hung call from wedging a server whose document lock is a single asyncio.Lock. It explains only part of the slowdown: switched off, creation is still 1.17× and 1.20× slower. The rest is extra work per call that 1.6 has not removed. A cProfile of the event-loop thread counts 491,071 function calls for the 2,000 creates, against v1.4.0's 319,038. Earlier READMEs said that switching the timeout off returned creation to v1.4.0's numbers. Measured this way, it does not. The region-query row, which moves the wrong way, shows this machine's noise floor (about ±10 %). Roadmap criterion 7 is not met and moves to 1.7.
Four mechanical feature tables ship empty. DIN 471/472 retaining-ring grooves, DIN 509 undercuts, DIN 332 centre holes and ISO 3601-2 O-ring grooves have their drawing code and their provenance tests, but no rows. A groove diameter written from memory is a wrong workshop drawing, while a narrow table is merely narrow. So every size is refused by name until rows verified against the standard's own table are transcribed. That is a data edit; each module's docstring says how.
Takeoffs are estimates, and they say so.
A layout length is the rectilinear minimum spanning tree of the tags a run connects, plus a stated vertical allowance, and it is labelled an estimate.
A P&ID length is used only when
drawing_scale_checkcalls the P&ID to scale.A power the P&ID does not state stays empty and becomes an open item, and no cable-section table is authored: a section comes only from your
section_rules.Where no callout names a panel, the nearest panel is inferred and flagged.
Detail copies of equipment are flagged, and excluded only when you ask.
The readers were tuned on the synthetic plant pair and on one real P&ID / layout pair that is not in this repository. Another drafting office's layer and text conventions may need vocabulary.
No Plant 3D. The roadmap's track D (read-only queries of a Plant 3D project) was dropped: the maintainer does not use Plant 3D, and a reader tested against nobody's real projects would be a guess. Roadmap criterion 5 is withdrawn, not met.
No REGION or 2D booleans headlessly. add_region() produces a REGION with zero ACIS bytes, and the greiner_hormann substitute loses 28.2% of the area on a square with one semicircular edge.
system_run_command / system_run_lisp are a guardrail, not a security boundary. The rejection message says so in those words. A 36-verb denylist refuses the obvious cases, but AutoCAD accepts hundreds of commands, and DANGEROUS_COMMANDS_ENABLED=true switches the list off entirely.
Path validation is per-tool, and unscoped until you scope it. With ALLOWED_PATHS empty (the default), the only positive bound is a ten-entry system-directory denylist that does not include C:/Users, /home, /root or /var. Set ALLOWED_PATHS.
Non-AutoCAD ProgIDs are unverified. CAD_PROGID changes which COM application the backend attaches to; nothing beyond the connection has been tested against BricsCAD, ZWCAD or GstarCAD.
Known limitations of the P&ID track
The router is orthogonal and blind. pid_line_draw picks auto from seven orthogonal candidates, by fewest bends then length:
straight;
one bend;
two bends through the midline;
a stub out of each port joined by three bends.
You can also take direct, or pass waypoints. It counts the lines it crosses (crossings comes back in every result, and pid_from_spec sums it), but it does not route around them. Obstacle-avoiding routing is not in 1.6; move the symbol or pass waypoints.
A foreign drawing is read at the confidence it earns, and no higher. A block this server did not place classifies at 0.6, with inferred ports, by its TAG-style attribute or a keyword in its name. It classifies at 0.3 when a line merely touches it, and a 0.3 guess can neither raise nor suppress a critique finding.
On the live engine, an INSERT turned off a right angle has members ActiveX cannot measure, so it reports an approximate box. pid_graph takes the tighter wall of that box and the attribute-inclusive box on every side. Even so, a line ending on such a body's true edge can still be reported dangling, with the nearest port as the hint. Read stats.confidence_min first.
Same-file only, DXF headlessly. Off-page connectors link within one drawing; links across files are not resolved. The headless engine reads DXF; a DWG P&ID is read through the live backend. There is no DEXPI/Proteus export and there are no ISA-5.2 binary-logic symbols in this release. Both cuts are recorded in the spec so nobody re-derives them.
Known limitations of the settings track
Layer states are ours. layer_state_save writes a portable snapshot into an ACADMCP_LAYERSTATES XRECORD. It survives save/reopen on both engines and travels with the DWG/DXF. It is not an AutoCAD LAYERSTATE and does not appear in the Layer States Manager, which is why system_capabilities reports layer_states as mode: "xrecord".
Six of the 22 environment tools need a live seat. Preferences, launching, the operator prompts and the five summary fields of document properties are refused headlessly with preferences / dwgprops / live_application / interactive_prompt. Each is a refusal, not a stub.
A .dwt template is the same case (dwt_write): a .dwt is a DWG container, so headlessly the template is saved as DXF. mleaderstyle_create is not such a case. ActiveX has no MLeaderStyle collection, but the ACAD_MLEADERSTYLE dictionary holds full IAcadMLeaderStyle objects, so both engines create leader styles.
A headless dimension does not re-render. On the ezdxf engine, dimstyle_modify reports dimensions_using_style and rerender_required: true, and the DIMENSION keeps its rendered block until it is redrawn. AutoCAD regenerates on the next regen.
Known limitations of the architecture track
Nominal, not standard. The furniture and sanitary blocks carry nominal catalogue sizes and say so. The stair tool reports the Blondel relation (2R + G within 600–650 mm) as a design rule, never as a building code. The arch layer colours are a repository convention: ISO 13567 fixes the names, not the colours. Labels speak English or Turkish; any other lang is refused with the list.
Configuration
Nothing loads a .env file — export these, or set them in your MCP client's env block.
Variable | Default | Purpose |
|
|
|
|
| COM ProgID the live backend attaches to |
|
|
|
|
| Vertical packs to advertise: |
|
|
|
|
| Expose the opt-in |
|
| Python logging level |
| (empty) | Comma-separated absolute paths the server may access |
|
| Maximum retained undo snapshots |
|
| Headless undo history depth; |
|
| Reject larger DXF input (512 MB); |
|
| Bound list/selection response sizes |
|
| Per-call live AutoCAD timeout (s); |
|
| Per-call headless timeout (s); |
|
| Allow blocked commands/LISP; reported as unsafe mode |
|
| Permit a non-loopback HTTP bind |
| (empty) | Bearer token required for remote HTTP |
Architecture
flowchart LR
A[MCP host / AI agent] --> B[FastMCP 3 server]
B --> C[Error · audit · timing · logging · capability-refusal middleware]
C --> D[Typed contract · 23 modules · 41 capability keys]
D --> E[COM backend<br/>single-STA thread]
D --> F[ezdxf backend<br/>asyncio.to_thread]
E --> G[Live AutoCAD]
F --> H[Headless DXF]
E --> I[Engineering · critique · scoring · delivery]
F --> IThe sequence in scripts/render_readme_showcase.py, which produced the hero sheet:
drawing_new() ISO linetypes + layers bootstrapped
drawing_apply_iso_layers("mech") ISO 128 lineweights per layer
drawing_settings({units: "mm", linear_precision: 2})
gear_draw_spur_front_view( involute flanks, not a decorated circle
module=6, teeth=24, center=[135, 172],
bore_diameter=40, keyway_width=12, keyway_depth=3.3)
gear_draw_section_aa(x_offset=300, face_width=46)
dimension_linear(...) ISO 129
dimension_diameter(..., fit="H7") deviations from authored ISO 286 tables
titleblock_apply_iso_a3(title="SPUR GEAR m6 z24", material="C45E", ...)
drawing_critique(focus=None) -> [] must be empty before finalize
view_screenshot() -> PNGThe full production loop adds drawing_preflight and drawing_plan at the front, drawing_refine after the critique, and layout_create + viewport_create + drawing_deliver at the end.
Development
uv sync --locked --all-extras
uv run pytest
uv run ruff check . && uv run ruff format --check .uv.lock pins the whole transitive graph, so this reproduces CI exactly. CI runs Linux (3.11 / 3.12) and Windows (mocked COM), plus package, Docker and MCP-registry jobs. The release gate runs the same three test lanes before anything reaches PyPI. Releases are tag-driven: git tag vX.Y.Z && git push origin vX.Y.Z.
Roadmap (1.7)
Speed. Win back the headless creation throughput that 1.6 lost against v1.4.0 (criterion 7): arm the per-call timeout only where a call can block, and remove the per-call work that came with it.
IEC 60617 electrical schematics. They reuse the P&ID track's symbol, port and graph machinery.
Transcribed rows for DIN 471/472, DIN 509, DIN 332 and ISO 3601-2, each verified against the standard's own table.
HATCH boundary geometry in
entity_get. 1.5 and 1.6 measure a hatch's filled area but do not hand back its loops.ezdxf.recoveras a fallback ondrawing_open.An allowlist of permitted AutoLISP heads, replacing the denylist. Enumerating dangerous symbols does not terminate.
Features ship when their contracts and limitations are testable — not when they make a longer checklist.
Star History
Author
Umutcan Edizsalan · Mechanical engineering work at Anka-Makine · GitHub @U-C4N
Built from production drawing work, then made model-agnostic through MCP.
License
mcp-name: io.github.u-c4n/autocad-mcp
This server cannot be deployed
Maintenance
Related MCP Connectors
DXF and PDF/X-4 for AI agents: structured facts, PNG renders, an interactive in-chat viewer.
Construction takeoff and estimating for AI agents. Measure a drawing PDF, export a priced estimate.
AI takeoff for construction: turn PDF blueprints into structured, traceable quantities.
- OwlCADOAuthcom.owlcad
Parametric 3D CAD for AI agents: build print-ready parts, check them, export STL, 3MF or STEP.
Related MCP Servers
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to drive live AutoCAD through COM on Windows or run headless DXF automation via ezdxf from one typed contract. It covers drafting, P&ID, mechanical, architectural, standards and takeoff workflows, with ISO GD&T and dimension-tolerance validation plus tools for reading, critiquing and diffing existing drawings.-
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to automate AutoCAD drawings through a typed contract that drives either a live AutoCAD COM session or a headless ezdxf engine. It covers mechanical, architectural, and P&ID drafting, ISO GD&T and tolerance validation, standards-compliant sheets, and drawing understanding and takeoffs.-
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to drive production-grade CAD automation through one typed contract with two engines: live AutoCAD via COM on Windows or headless DXF via ezdxf anywhere. Supports drawing and reading mechanical parts, architectural floor plans, P&ID sheets, dimensions, ISO/ANSI standards validation, and quantity takeoffs into spreadsheets.-
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to create, edit, and interrogate CAD drawings through one typed contract, driving either a live AutoCAD session over COM or a headless ezdxf engine on any platform. It covers ISO-standard drafting, mechanical and architectural parts, P&ID schematics, dimension-tolerance and GD&T validation, plus reading existing drawings and generating takeoff workbooks.-