Author and iterate on 3D-printable parts as parametric Python (trimesh + manifold3d + shapely), then view and screenshot them headlessly to verify. Use when the user wants to design, modify, or print a mechanical part, gear/worm drive, enclosure, bracket, or any FDM/resin model, anything involving STL/3MF/GLB, build123d-style geometry, watertight CSG, or "make this part / make it bigger / make it printable". Covers the view-screenshot-iterate loop and FDM design rules. For Bambu .3mf slicer export see the bambu-3mf-export skill; for importing STEP/IGES/foreign CAD see foreign-cad-import.
$npx -y skills add m-esm/3d-print-modeling --skill 3d-print-modelingInstalls into the current project.
Run `npx skills use "https://github.com/m-esm/3d-print-modeling" --skill "m-esm/3d-print-modeling"` and follow the generated skill instructions now. Read its complete output, redirecting it to a temporary file first if necessary. Resolve relative paths from the supporting-files directory it provides.
Use the skills in "https://github.com/m-esm/3d-print-modeling" that are relevant to the current task. Run `npx skills add "https://github.com/m-esm/3d-print-modeling"` and select the relevant skills, then follow their instructions.
| 1 | # 3d-print-modeling — a Claude Code skill for parametric 3D-print parts |
| 2 | |
| 3 | [](LICENSE) |
| 4 | [](https://code.claude.com/docs/en/skills) |
| 5 | [](#install) |
| 6 |  |
| 7 | |
| 8 | Design FDM 3D-print parts as **parametric Python** (`trimesh` + `manifold3d` + `shapely`, or `build123d`), then **view and screenshot them headlessly** so Claude checks the geometry by eye on every change. No GUI CAD (no OpenSCAD, FreeCAD, or Fusion). The geometry engine is pip-installable, the viewer runs in a browser, and "done" means Claude actually looked at the render from six angles, not "it's watertight, ship it." |
| 9 | |
| 10 |  |
| 11 | |
| 12 | > The bundled self-contained parts viewer: every STL in a project, gridded on the print bed, grouped by category, with a searchable panel and per-part dimensions. One double-click HTML file, no server. |
| 13 | |
| 14 | ## Why |
| 15 | |
| 16 | LLMs are good at writing the Python that generates a mesh and bad at noticing the bolt hole missed the shaft, the bracket is mirrored, or two parts collide. Numeric checks (`is_watertight`) pass while the part is visibly wrong. This skill closes that loop: it makes Claude **render the part and read the image** before claiming the change works, the same discipline a human modeler uses staring at the viewport. |
| 17 | |
| 18 | ## What it does |
| 19 | |
| 20 | - **Parametric-first.** One `build.py` with a `PARAMETERS` block is the source of truth. Edit values, rerun, never hand-edit mesh output. |
| 21 | - **View → screenshot → iterate.** `serve.py` + `shoot.py` render iso / front / side / top + two section cuts to PNG via headless Chromium. Claude looks at the part from multiple angles, and the section cuts confirm internal features (bores piercing, cavities connecting, wall thickness). |
| 22 | - **Parts-kit fan-out.** Want a whole family of parts at once? The skill fans out one subagent per part against a shared `lib.py` helper API, then builds them in a single pass. Measured: 19 parts, every one watertight on first build. |
| 23 | - **Two viewers.** `viewer_glb.html` for a single live-reloading assembly GLB (per-part toggles, explode slider, section cut, L/W/H dimension lines, Z-up). `parts_viewer.py` bundles a directory of STLs into the one-file HTML grid shown above. |
| 24 | - **FDM design rules + mechanisms references** loaded on demand: print orientation, self-supporting geometry, minimum feature size, PLA vs PETG, gears and worms, press-fits and clearances, bearings, snap joints. |
| 25 | - **Engine-agnostic.** Use `trimesh` + `manifold3d` for mesh surgery on downloaded STLs, or a real BREP kernel (`build123d` / `CadQuery`) for new parts with native fillets, chamfers, and threads. Both are `pip install`, no system CAD. |
| 26 | |
| 27 | Pairs with **[bambu-3mf-export](https://github.com/m-esm/bambu-3mf-export)** to turn finished STLs into a sliceable Bambu Studio `.3mf` project with print settings baked in. |
| 28 | |
| 29 | ## Install |
| 30 | |
| 31 | ### Option 1: Manual (works everywhere, all projects) |
| 32 | |
| 33 | ```bash |
| 34 | git clone https://github.com/m-esm/3d-print-modeling ~/.claude/skills/3d-print-modeling |
| 35 | ``` |
| 36 | |
| 37 | Restart Claude Code. The skill auto-loads when you describe a modeling task, or run `/3d-print-modeling`. |
| 38 | |
| 39 | ### Option 2: Plugin marketplace (supports updates) |
| 40 | |
| 41 | ``` |
| 42 | /plugin marketplace add m-esm/3d-print-modeling |
| 43 | /plugin install 3d-print-modeling@3d-print-modeling |
| 44 | ``` |
| 45 | |
| 46 | Update later with `/plugin marketplace update 3d-print-modeling`. |
| 47 | |
| 48 | ## Usage |
| 49 | |
| 50 | Describe the part. Claude loads the skill and runs the loop: |
| 51 | |
| 52 | > Make a parametric M8 bolt and a matching nut, then a wall bracket they bolt through. |
| 53 | |
| 54 | > This part is too flexible. Thicken the spine to 4mm and add a 45-degree gusset, then show me the section cut. |
| 55 | |
| 56 | > Give me a family of 42mm beam connectors: corner, tee, cross, end cap. |
| 57 | |
| 58 | Or invoke it explicitly with `/3d-print-modeling`. |
| 59 | |
| 60 | ## Requirements |
| 61 | |
| 62 | - Python 3.9+ for the trimesh path (Python 3.10+ for the `build123d` BREP path). |
| 63 | - Install the pinned toolchain: |
| 64 | ```bash |
| 65 | pip3 install --user -r scripts/requirements.txt |
| 66 | python3 -m playwright install chromium |
| 67 | ``` |
| 68 | |
| 69 | ## What's in here |
| 70 | |
| 71 | ``` |
| 72 | SKILL.md the skill itself (workflow + FDM rules Claude reads) |
| 73 | references/ |
| 74 | fdm-design-rules.md print orientation, supports, min feature size, PLA vs PETG |
| 75 | mechanisms-and-fits.md gears/worms, keyed bores, press-fits, bearings, clutches |
| 76 | scripts/ generic, copy into a project as needed |
| 77 | serve.py localhost static server for the viewer |
| 78 | shoot.py headless multi-angle Playwright renders |
| 79 | viewer_glb.html Three.js assembly viewer (toggles, explode, section, dims) |
| 80 | vie |