
engineering-drawing
Make an engineering drawing of a part as a PDF - orthographic views with hidden lines and centre marks, real dimensions, hole callouts, notes and a title block on ISO sheets, all projected from the part's geometry so the drawing follows the model. Use when the user asks for a drawing, a dimensioned sheet, shop or manufacturing drawings, a print, or "2D views of this part".
- Installs
- 2.3K
- Last 24h
- +86
- Trending rank
- #2192
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/earthtojake/text-to-cad --skill engineering-drawing- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads engineering-drawing automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Engineering drawing
Provenance: maintained in earthtojake/text-to-cad. Use the installed local skill files as the runtime source of truth.
An engineering drawing is a DOCUMENT derived from a part. cadgen.eng_drawing
projects views from the part's geometry, places dimensions between points ON
that geometry, finds centre marks on it, and lays the result out on an ISO
sheet with a frame and a title block. Change the model, rerun the drawing
script, and the views, hidden lines and measured values move with it. Nothing
on the sheet is drawn by hand, and nothing on it is a number you typed unless
you chose to override a value.
The output is one PDF. That is what a shop receives and what every
operating system opens. No DXF is written, nothing is paired or linked, and
there is no CLI: the script is the interface. $dxf makes cut layouts and flat
patterns, which are toolpaths, not documents; the two are different jobs.
Setup
Run cadgen through uv, so this skill's commands share one installation, and its warm build daemon, with the CAD app's server:
cadgenbelow meansuvx --no-config --managed-python --python 3.13 --from cadgen==0.7.26 cadgenpythonbelow meansuvx --no-config --managed-python --python 3.13 --from cadgen==0.7.26 python
The first run downloads that installation; later runs reuse it.
Workflow
-
Get the part.
cadgen.read_step(Path(__file__).parent / "../STEP/part.step")reads the artifact a@stepmodel wrote (runpython <model>.pyfirst); a live build123d shape works just as well. The drawing documents geometry, it does not build it. -
Write
<name>_drawing.pybeside the model, from the template. Import the model facts the dimensions reference (hole pitch, overall size, wall) from the model module rather than retyping them, so moving a feature moves its dimension. -
Place views with
sheet.three_views(part, iso=True), which returns FOUR views: top, front and right in third angle with room for two rows of dimensions, plus an isometric in the free corner.sheet.three_views(part)returns three. Usesheet.view(part, name, at=(x, y))(sheet millimetres from the bottom-left corner; A3 is 420 × 297, A4 is 297 × 210) only for a custom layout. -
Dimension what a maker needs, in MODEL coordinates: overall size per view (
view.overall()), feature positions and sizes (view.dim, withtol=orfit=where the design requires one), holes as callouts (view.hole: thru, depth, counterbore, countersink, thread), and notes with leaders (view.note). Leavetextunset so the dimension is measured; give a value only where the model does not define it. Leaveoffsetunset too and the dimension takes the next free row outside the view; pass one only to place a dimension deliberately, and remember it is measured from the dimension's own points, not the view's edge. Keep notes few and short; one wider than the sheet's note column is refused, andnotes=takes a LIST (notes="BREAK EDGES"is a sequence of eleven characters, so it is refused too). -
Run
python <name>_drawing.py. It prints the PDF it wrote, and anything it noticed while drawing — read those first:- "measures blank paper": the dimension's model points do not land on the view's geometry. Almost always the part was built from a corner and the script assumed it was centred. Check the part's bounding box.
- "annotation overlaps": two callouts print on top of each other, usually
one view's outermost dimension against the label of the view above it.
Pass a bigger
three_views(gap=...)or place one withoffset=. The text is measured as the renderer draws it, glyph by glyph, so this fires on ink and not on markup: a chain of toleranced dimensions is silent when the values clear each other.
Steps 3 and 5 stand on their own: a sheet of views with no dimensions on it yet is a drawing, and writes its PDF.
When running unattended, set
MPLCONFIGDIRto a writable directory so matplotlib's font cache does not warn. -
Read the PDF and fix what collides. Check that no dimension text sits on a view, that hidden lines appear where features are behind faces, that every hole has a centre mark, and that no leader crosses the part. Very small dimensions (a few mm) put their value on their own extension line; dimension the larger feature instead. Move
at=oroffset=and rerun.
What the sheet contains
- Layers with meaning:
VISIBLE(heavy outline),HIDDEN(dashed),CENTER(centre marks),DIM,NOTES,TITLE,SHEET(frame), each printed at its own weight — 0.5 mm down to 0.18 mm, so thick reads against thin on paper. An edge is drawn once: a silhouette that the kernel returns as both visible and hidden stays onVISIBLE. Hidden TANGENT transitions are not drawn at all — a fillet running into a face, or the seam where a cylinder closes on itself, marks nothing a shop can see, and drawn dashed it reads as a hidden edge that is not there (on a bore, as a line down the hole's own axis). - Dimensions measured from the geometry, with filled arrowheads and witness lines, and true-size values at any drawing scale.
- A title block with title, part number, material, author, scale, units,
projection, revision,
SHEET n OF mand the drawing function's name; numbered notes above it (the general tolerance, when given, is note 1); a revision table top-right whenrevisions=is given. Text longer than its cell is set smaller, and cut with an ellipsis rather than overrun. - PDF bytes that are a function of the content: no creation date is stamped, so an unchanged drawing rebuilds to an identical file.
What fails loudly
The script raises rather than writing a wrong or missing document:
- Views that run off the frame, naming a scale that has been laid out and verified to fit, or saying that no standard scale does.
- A part argument the vocabulary does not define: an unknown view name, sheet
size or projection,
orientation=other than"h"/"v", a negative or zero diameter, a counterbore that is not a(diameter, depth)pair, atolthat is not a number or a pair, a hole that is boththruand given a depth,notes=orrevisions=given a bare string, a note wider than the sheet,angle()legs that are collinear or zero-length, a non-finiteat=oroffset=. - A missing renderer. The PDF is the drawing, so no matplotlib is a failure, not a skipped half. A failed render leaves no file behind.
out=missing or not naming a.pdf, at import time.
Limits to state in the handoff
- Tolerances come only from
tol=,fit=andgeneral_tolerance=that you write; get the values from the design requirements or the user, never invented. A dimension without one is nominal. - Views are orthographic projections with hidden lines from the kernel; no sections, details, or auxiliary views yet. Say what a view does not show.
- The sheet keeps callouts clear of the views it knows about, and reports annotation that still prints over other annotation, but it does not check annotation against line work. Read the PDF.
FAQ
What does the engineering-drawing skill do?
Make an engineering drawing of a part as a PDF - orthographic views with hidden lines and centre marks, real dimensions, hole callouts, notes and a title block on ISO sheets, all projected from the part's geometry so the drawing follows the model. Use when the user asks for a drawing, a dimensioned sheet, shop or manufacturing drawings, a print, or "2D views of this part".
How do I install engineering-drawing?
Run npx skills add https://github.com/earthtojake/text-to-cad --skill engineering-drawing in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/engineering-drawing/ (personal) or .claude/skills/engineering-drawing/ (project).
Which AI agents can use engineering-drawing?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is engineering-drawing safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains engineering-drawing?
It is published by earthtojake in earthtojake/text-to-cad. It has 2,293 recorded installs.
More from earthtojake/text-to-cad
cad
earthtojake/text-to-cad
Create/edit parametric CAD models, organize CAD projects, export STEP/STL/3MF/GLB files, resolve prompt references, and measure geometry with cadgen. Open and visually review existing STEP/STP, STL, 3MF and GLB files in CAD Viewer.
step-parts
earthtojake/text-to-cad
Find, evaluate, and download common purchasable CAD parts from step.parts, including named off-the-shelf actuators, servos, motors, electronics boards, connectors, screws, bolts, nuts, washers, bearings, standoffs, and other catalog components. Use when Codex needs to search the hosted step.parts catalog before creating simplified placeholder geometry, resolve fuzzy part names, standards, aliases, or dimensions, choose a matching part, fetch a canonical .step file, verify checksums, or use the step.parts API/OpenAPI/catalog endpoints for standard part discovery.
sdf
earthtojake/text-to-cad
SDFormat/SDF model and world authoring, validation, and simulator handoff. Use for .sdf files, SDFormat XML, models, worlds, links, joints, poses, frames, inertials, visual/collision geometry, mesh URIs, sensors, lights, physics, plugins, includes, Gazebo, static SDF review, or simulator-specific metadata. Do not use for signed-distance-field geometry. Open and visually review existing SDF files in CAD Viewer.
urdf
earthtojake/text-to-cad
URDF robot description authoring and validation. Use when creating, editing, inspecting, validating, or debugging .urdf files, robot links, joints, limits, inertials, visual/collision geometry, mesh references, frame conventions, or robot-description artifacts. Use the SRDF skill for MoveIt2 semantic groups and IK/path-planning semantics; use the CAD skill for STEP/STL/3MF/DXF/GLB outputs. Open and visually review existing URDF files in CAD Viewer.
srdf
earthtojake/text-to-cad
MoveIt2 SRDF authoring, validation, and planning-semantics workflow. Use when creating, editing, inspecting, or validating .srdf files, MoveIt planning groups, virtual joints, passive joints, end effectors, group states, disabled collisions, URDF-paired planning semantics, or SRDF handoff for live review. Use the URDF skill for robot structure and the SDF skill for simulator descriptions. Open and visually review existing SRDF files in CAD Viewer.
sendcutsend
earthtojake/text-to-cad
Review DXF and STEP/STP uploads for SendCutSend.com orders using its ordering guide, catalog, and specs. Use only for SendCutSend.com preflight reports covering upload readiness, selected material/SKU/thickness/service availability, and service-specific checks for laser cutting, CNC routing, bending, tapping, countersinking, hardware insertion, and finishing.
Popular docs & writing skills
grill-with-docs
mattpocock/skills
A relentless interview to sharpen a plan or design, which also creates docs (ADR's and glossary) as we go.
lark-markdown
open.feishu.cn
飞书 Markdown:查看、创建、上传、编辑和比较飞书中的原生 Markdown 文件。当用户要操作飞书 Markdown 文件,或比较其远端版本及本地草稿时使用。纯本地 Markdown 文件操作不触发本 skill。不负责将 Markdown 导入为飞书在线文档,也不负责文件搜索、权限、评论、移动、删除等云空间管理操作。
writing-beats
mattpocock/skills
Writing, exploit; assemble raw material into a journey of beats, grounding each term before a beat leans on it.
writing-shape
mattpocock/skills
Writing, exploit: shape raw material into an article, paragraph by paragraph.
writing-fragments
mattpocock/skills
Writing, explore: mine raw fragments, no structure yet.
writing-for-agents
mattpocock/skills
Writing documents for agents. Use when creating or editing skills, or modifying AGENTS.md or CLAUDE.md.