openscad-designer
Skill3 starsChanged 4 months agoMITView on GitHub
Creates, validates, renders, and slices parametric 3D models with OpenSCAD. Saves each model in its dedicated subfolder and executes FDM printability audits.
In this repository5 other files it gives its agents.
- .agents/AGENTS.mdAGENTS.md
- export-stlSkill
- fdm-printability-auditorSkill
- preview-scadSkill
- validate-modelSkill
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 3 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 14
FDM Printability Quality Gate: Before finalizing any code, you MUST execute the quality gate defined in …
- Very specific: line 15
Workflow & Rules: Always follow the modeling rules and Customizer standards defined in ai/shared/instructions/openscad-workflow.md.
- Very specific: line 16
Hardware & Dimensions: Read ai/shared/instructions/libraries.md for standard hardware tolerances (M3, M4, M8, ESP32, bearings).
- Very specific: line 23
If openscad is not in the system PATH, use the absolute path:
- Distinctive: line 39
When the user requests a 3D model:
- Very specific: line 43
Write all output files into the models subfolder models/<project_name>/gemini/:
- Very specific: line 51
Create <project_folder>/gemini/model.scad with all key dimensions, tolerances, and part selectors parameterized near the top.
- Very specific: line 52
Use dynamic resolution via $preview for fast rendering:
- Very specific: line 73
Follow the 6 commandments in .agents/skills/fdm-printability-auditor/SKILL.md:
- Distinctive: line 94
Verify zero collisions, 100% flat bed contact, self-supporting overhangs ($\le 45^\circ$), and $15\text{ mm}$ inter-part clearance gaps.
- Distinctive: line 111
README.md: Create human-readable summary with render previews, PrusaSlicer print metrics table, and recommended 3D print settings.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
OpenSCAD Expert & Slicing-Aware Designer Skill
You are an expert in parametric 3D design and FDM 3D printing using OpenSCAD. Your goal is to create clean, 100% printable, structurally sound, and support-free .scad files.
📚 References & Core Instructions
- FDM Printability Quality Gate: Before finalizing any code, you MUST execute the quality gate defined in
.agents/skills/fdm-printability-auditor/SKILL.md. - Workflow & Rules: Always follow the modeling rules and Customizer standards defined in
ai/shared/instructions/openscad-workflow.md. - Hardware & Dimensions: Read
ai/shared/instructions/libraries.mdfor standard hardware tolerances (M3, M4, M8, ESP32, bearings).
🛠 Prerequisites & System CLI
- Assume OpenSCAD is installed on the system.
- If
openscadis not in the system PATH, use the absolute path:- Windows:
& "C:\Program Files\OpenSCAD\openscad.com"(useopenscad.comfor synchronous CLI calls). - macOS:
/Applications/OpenSCAD.app/Contents/MacOS/OpenSCAD - Linux:
/usr/bin/openscad
- Windows:
- Slicer CLI Engine (Optional for Empirical Metrics):
- Dynamically detect available Slicers on PATH (
prusa-slicer-console,prusa-slicer,orca-slicer,bambu-studio,curaengine). - Common fallback paths:
- Windows:
"C:\Program Files\Prusa3D\PrusaSlicer\prusa-slicer-console.exe","C:\Program Files\Tools\PrusaSlicer\prusa-slicer-console.exe","C:\Program Files\OrcaSlicer\orca-slicer.exe" - macOS:
/Applications/PrusaSlicer.app/Contents/MacOS/PrusaSlicer - Linux:
/usr/bin/prusa-slicer
- Windows:
- Note: If no Slicer CLI is detected, skip Slicer pass and perform the 100% verified OpenSCAD CSG Render Audit.
- Dynamically detect available Slicers on PATH (
🔄 Execution Workflow & Render Loop
When the user requests a 3D model:
- Create Project Directory Structure:
- Choose a concise project name (e.g.
soap-holder). - Write all output files into the models subfolder
models/<project_name>/gemini/:models/ └── <project_name>/ └── gemini/ ← active agent output directory
- Choose a concise project name (e.g.
- Generate Parametric Code (
model.scad):- Create
<project_folder>/gemini/model.scadwith all key dimensions, tolerances, and part selectors parameterized near the top. - Use dynamic resolution via
$previewfor fast rendering:$fn = $preview ? 32 : 64; - Standardize Render Mode Selector:
/* [Render Mode & Part Selector] */ part = "all"; // ["all": Assembled View, "part1": Part 1 Only, "print_bed": Both Parts Flat on Z=0, "exploded": Exploded View] - Include header metadata:
// AI Agent: openscad-designer (Gemini 3.6 Flash) // Project: <project_folder> // Date: YYYY-MM-DD // User Verification Checklist // - Geometry reviewed manually: [ ] // - Render checked in OpenSCAD: [ ] // - Printed successfully: [ ]
- Create
- Execute FDM Printability Audit:
- Follow the 6 commandments in
.agents/skills/fdm-printability-auditor/SKILL.md:- Multi-Axis Clearance (0.60–0.80mm sliding fit).
- Z-Bound Safety ($Z \ge 0$).
- 100% Flat Bed Contact.
- Per-Part Optimal Orientation & Universal Disjointness Collision Audit (
part == "print_bed"). - Annular Ring Subtractions.
- Full-Pass Through-Holes.
- Follow the 6 commandments in
- Multi-View Rendering & Historical Archiving:
- Execute multi-view render script:
powershell -ExecutionPolicy Bypass -File ai/shared/scripts/render-scad.ps1 -InputFile <project_folder>/gemini/model.scad -MultiView -Iteration <N> - Render print bed layout preview:
& "C:\Program Files\OpenSCAD\openscad.com" -D 'part="\"print_bed\""' --autocenter --viewall --imgsize=800,600 --camera=0,0,0,120,0,315,200 -o <project_folder>/gemini/model_preview_print_bed.png <project_folder>/gemini/model.scad - Perform cross-section debug render with
#highlights if hidden internal geometry exists.
- Execute multi-view render script:
- Visual Validation:
- Inspect
model_preview_iso.png,model_preview_top.png,model_preview_print_bed.png, andmodel_preview_debug.png. - Verify zero collisions, 100% flat bed contact, self-supporting overhangs ($\le 45^\circ$), and $15\text{ mm}$ inter-part clearance gaps.
- Inspect
- Export Binary STL File:
- Export printable STL with
-D 'part="\"print_bed\""':& "C:\Program Files\OpenSCAD\openscad.com" -D 'part="\"print_bed\""' --export-format binstl -o <project_folder>/gemini/model.stl <project_folder>/gemini/model.scad
- Export printable STL with
- PrusaSlicer CLI Empirical Validation:
- Execute headless slicing on exported STL:
& "C:\Program Files\Tools\PrusaSlicer\prusa-slicer-console.exe" --export-gcode --info <project_folder>/gemini/model.stl - Parse
model.gcodeforestimated printing time,filament used [cm3],support_material = 0, andmanifold = yes.
- Execute headless slicing on exported STL:
- Documentation & Logging:
model_log.json: Record prompt, execution time, iterations, and"slicer_metrics"object.README.md: Create human-readable summary with render previews, PrusaSlicer print metrics table, and recommended 3D print settings.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

