Prompt Engineering for Better CAD Results
You've mastered basic prompting: you know to include dimensions, name the shape, and describe features in order. This guide covers the advanced techniques that separate good results from great ones.
1. Decomposition: Break Complex Parts Into Steps
Complex parts often fail because the AI tries to do too much at once. Instead of one massive prompt, use the feedback loop to build incrementally:
- Generate the base shape with major dimensions
- Use Give feedback to add one set of features at a time
- Approve when the base is correct, then add features
Example: instead of one huge prompt for a complex enclosure, start with just the box: "A 100×60×40mm box with 2mm walls, open top." Get that right, then add: "Now add a 20×12mm USB-C cutout on the front face, centered vertically and horizontally." Then: "Add four M3 boss features on the inside corners, 4mm tall with 1.6mm hole for heat-set inserts."
2. Negative Constraints
Tell the AI what you don't want. This is especially effective for preventing the AI from adding features you didn't ask for:
- "No fillets or chamfers"
- "Keep the geometry simple: no decorative elements"
- "The bottom face must be perfectly flat: no draft angles"
- "Avoid using sphere primitives"
3. Reference Points and Coordinate Systems
Models are built around the origin. Specifying positions relative to the model origin helps the AI place features correctly:
"The main body is centered at the origin, 80mm long along the X axis, 50mm wide along the Y axis, and 20mm tall. The mounting hole is at position (30, 0, 0): 30mm from center on the right side."
4. Functional Descriptions
Sometimes describing the function of a feature produces better results than describing its geometry. Instead of "a slot 6mm wide and 2mm deep," try "a groove that fits a standard 6mm rubber O-ring." The AI knows the standard proportions for common features.
5. Repair Loop Awareness
The auto-repair loop runs when scripts fail. You can take advantage of this by writing slightly over-specified prompts that include features the AI might initially struggle with: the repair loop usually converges to a working solution within 2–3 attempts for most complexity levels.
6. Asking for Alternatives
Use the feedback field to request alternative designs: "Regenerate this part but make the mounting flange 10mm wider on each side: show me a version that would work for a larger bolt pattern."
7. Material-Informed Design
If you tell the AI your print material, it can make better decisions about wall thickness and feature size:
"Design this for PETG printing. Use minimum 2.5mm walls throughout. The snap arms should be 1.8mm thick to balance flexibility and strength in PETG."
8. Give Exact Dimensions in Millimeters
FreeTextToCAD assumes millimeters unless you say otherwise, and the generator does far better when every key feature has an explicit mm size. "A 60×40×20 mm box with 2 mm walls and a 3 mm hole" produces a reliable part; "a small box" leaves the AI guessing. If you think in inches, give the inch value and let the tool convert — but naming the number is what matters.
9. When All Else Fails: Reset and Simplify
If a prompt consistently fails after 5 repair attempts, step back dramatically. Generate the simplest possible version of the shape, then iterate forward. Almost all complex parts can be reached through iterative refinement from a simple base.
For more, see our full documentation or our guide on writing effective prompts.