# CAD detailed design

**Purpose:** take an approved concept (from `cad-concept`) to a printable, self-reviewed, parametric part — measured before it is modelled, with a printability audit that gates the export and a release that doesn't ship stale documentation.
**Reads:** `prints/<slug>/design-spec.md` + its sketch (the handoff from `cad-concept` — treat it as the brief, and work from it alone); `prints/README.md` (printer, toolchain, slice conventions, measured fits, how to run CadQuery); the filament I actually have on hand.
**Writes / proposes:** source, STL(s) and README in `prints/<slug>/` (the folder and its `measurements.md` usually exist already, from `cad-concept`); new rounds in `measurements.md`; a line in `prints/README.md` once it's actually printed.

## Prompt body

### Before anything: confirm the toolchain is my decision

**Do not start until the spec carries an explicit `Toolchain:` line naming CadQuery or OpenSCAD as decided by me.** If it's missing, ambiguous, or was chosen by a model rather than by me, **stop and ask** — state the trade-off in two lines and wait:

- **CadQuery** → STEP for free; the part can enter real CAD, be sectioned, or be handed on. Slower, fillets can fail.
- **OpenSCAD** → **no STEP, ever** (mesh-only, no B-rep to export — wanting it later means remodelling from scratch). Fast, small meshes.

This is not a default you may infer from what's convenient, from what the printer README uses, or from what you're most fluent in. It determines whether the part is reusable years from now, and it cannot be reversed without starting over. Use exactly what the line says, and if the geometry makes that choice painful, say so and ask rather than switching.

### Then build

Build what `design-spec.md` specifies. You own geometry, tolerances, print orientation, fasteners, radii and manufacturability. Don't re-open the concept without telling me first — if the geometry forces an architecture change, stop and say so rather than quietly building something else.

**The spec is the brief.** It was written to be sufficient without the conversation that produced it — a different model may have written it. Use the toolchain it names. Treat its hard constraints as binding, its `[assumed — verify]` tags as unverified, and its "out of scope" list as off limits. **Its calculations are assumptions too.** Re-derive any calculation a feature depends on before modelling it, and check that the physical model behind it is right: a hoop-strain figure for a lip cut into solid plastic assumes a ring that can stretch, and that ring can't. If the spec is genuinely missing something you need, say which item and ask; do not fill the gap by inference, because an invented number in a spec-driven handoff is invisible to everyone downstream.

### Measure before you model, not after

**Open by listing every `[assumed — verify]` number in the spec that actually drives geometry** — stock dimensions, insert thickness, adhesive thickness, fastener specs — and say what each one moves if it's wrong. Then: **if the physical stock is already in hand, or arrives inside the build window, stop and ask for calipers on those items before modelling.** Every request for a measurement, a yes/no check or a coupon result goes in as a new dated round of fill-in bullets in `measurements.md`, in the format `cad-concept` deliverable 5 sets (create the file if it's missing). Then read my answers from the file, not from chat. A rebuild on measured numbers is not a revision, it is the same build done twice, and it lands at the worst moment — late, under deadline, after the prose has been written. The exception: if every open item is a yes/no check that can't change the geometry (are the screws self-tapping, does the part sit flat), model now and say so in one line.

**A vendor's nominal size is an assumption, not a measurement.** "4×6 in, 26 gauge" is what the listing says; 102.1 × 151.5 × 0.50 mm is what the sheet is. Tag nominal figures `[assumed]` even when they come with three decimal places, and never let one silently become the number a clearance is derived from. The home-verification checklist in §5 stays either way — it covers what can only be checked in situ — but it is a backstop, not the plan.

### 1. Parametric source

Every dimension that could plausibly change is a **named parameter at the top of the file**, with a one-line comment saying what it's for and where the number came from. At minimum: device W/D/H, fit clearance, wall thickness, retention overlap, mounting-hole spacing, fastener sizes, cable diameter and bend radius, and every site dimension I have to verify.

- **Derive, don't duplicate.** Anything computable from another parameter is a derived expression, not a second literal.
- **Guard the intent with assertions.** Where a relationship must hold for the design to work — driver access clears the gusset, bend radius ≥ 6 × cable Ø, screw sits outside the plate width — write it as an `assert`, so a future parameter change fails loudly instead of silently producing a broken part. This is cheap and it is what makes the model safe to modify in six months.
- **Bake the print orientation into the export**, so the STL cannot be mis-oriented by accident.
- **Every clearance names what it buys and what it takes from.** Slop is never free — it is always subtracted from something else in the stack, and the comment has to say what. A pocket 0.2 mm deeper than its insert is 0.2 mm stolen from the adhesive's compression behind it. When an assumed dimension later becomes measured, **tighten the clearance that was covering for it in the same pass**, or the slop outlives its reason.
- **Clearance for a pocket that receives a physical insert is a process number, not a fit number.** First check `prints/README.md` § Measured fits. A matching row there beats any rule of thumb. Otherwise, split by what the pocket has to do. A **drop-in** pocket (the insert just has to enter, and something else holds it) starts around 0.2–0.3 mm per side. A **press or retaining** fit is much tighter: a knurled head in PETG was loose at 0.20 and right at 0.08–0.10. Either way, say in the comment what failure the clearance buys off, and add a row to Measured fits once a print settles it.
- **Quantize cosmetic depths to the layer height.** An engraving at 0.3 mm on a 0.20 mm layer is one-and-a-half layers and prints as one; at 0.4 it is exactly two. Derive such depths from `layer_h` rather than typing a decimal that looks right.
- Regenerate into a staging directory and copy approved outputs across; don't overwrite a released build in place.

### 2. Self design review — revise the CAD, don't just list findings

Work the checklist and **fix what you find**. A review that reports problems and ships them anyway is worse than no review, because it reads like diligence.

- Assembly and removal path (with the device in and out)
- Interference with everything nearby: outlet, switch, adapter, cables, doors, hands
- Can it fall out accidentally? Under what motion?
- Load path into the wall or surface — name the reaction at each fastener
- **FDM printability and support requirements** — see the gate below
- Minimum wall thickness, and where the thinnest section is
- Tolerance sensitivity — what breaks first if the printer is 0.2 mm off
- Stress concentrations, and the radii that address them
- Cable bend radius and routing
- Access to ports, buttons, LEDs
- Airflow / heat
- **Screw-head clearance and straight-in driver access for every fastener**, device installed *and* removed. Check the driver body, not just the screw axis.
- **Before exporting a second variant, check whether a rotation or a flip of the first covers it.** Two mirrored parts are two things to print, label, store and keep in sync; one flat part flipped over is one.

**If anything is bonded, the adhesive footprint is geometry.** A tape or glue line designed by omission is the single most revised thing in a build like this, and every one of its failures is invisible in a render:

- **Reference the bond plane to the face that actually backs it**, not to the nearest rim. If an insert sits below the rim, a recess cut from the rim leaves the adhesive barely compressed over exactly the area that carries the load.
- **State the compression budget** — uncompressed thickness, in-service thickness, and the recess depth that delivers it — and assert it, so a later parameter change can't quietly consume it.
- **No dry hard stop outboard of the bond.** Printed material landing directly on the substrate at the perimeter is a hinge at the one place a bonded panel peels from. Carry the bond out to the edge and leave a deliberate bonded ledge; make its width its own parameter rather than "whatever the border happens to be."
- **Internal ribs and stiffeners land in the bond too.** A full-height rib crossing the bonded area is a hard line resting on an imperfect surface; a rib cut down to the bond plane is a bonded line. On a substrate that isn't flat, the second is worth more.

**Name the cosmetic face, and defend it.** Say in the review which face is the one that gets looked at, then:

- **Nothing on it that serves the builder.** Alignment marks, field outlines and assembly aids read as an engineering drawing on a finished object. If the information is needed, put it in the README.
- **If the cosmetic face is the bed face, text and artwork on it must be mirrored in the model** — and the source has to say so at the mirror, because it looks like a bug forever afterward.
- **Show a render of the cosmetic face and get sign-off before the first slice.** Cosmetic problems are the ones that survive every geometric check and are only ever found by looking.
- **Artwork is a separate approval loop from geometry.** Preview the whole family together, in its real colours, before it becomes N exported bodies — a set is judged as a set, and mixed outlines read as indecision rather than variety. Respect the stroke floor (nozzle width is the hard minimum; text sizing is arithmetic, not taste), and remember that a motif hollowed into line-work only survives if it was made of structure — a solid mass hollowed becomes an outline of nothing.

### 3. Printability audit — this gates the export

**Before you export, and before you say anything about supports, produce this table:**

| | |
|---|---|
| Every bridge | span in mm, and what it's spanning between |
| Every downward surface steeper than 50° | area, location, and the angle |
| Every unsupported island | where it starts in Z, and its area |
| Every horizontal cylinder or pin | diameter and length |

Then, and only then, state whether supports are needed. **Do not claim "no supports" without this table.** If a feature fails the audit, change the geometry — a self-supporting chamfer constant applied consistently (e.g. run/rise 1.2 → 40°, inside the 45° limit) is better than case-by-case judgment and gives you one number to tune.

**Measure, don't estimate.** Any claim about overhang angles, bridge spans, mesh size, mass or print time must come from the actual exported geometry. If you can't measure it, say "not measured" rather than producing a plausible number.

Also check: watertight, single body, sitting at z = 0, within my printer's build volume, and a mesh size a slicer can actually open — if fillet technique has pushed the STL past ~20 MB, reduce arc resolution rather than shipping it.

**If hardware gets dropped into the print mid-job, the audit has to state the pause height** — the exact Z, the layer number at the stated layer height, what goes in, and what happens if the pause is skipped (usually: the roofs over the cavities print into air). A cavity roofed over an insert is not a bridge failure *provided* the insert is there; without the pause it is the worst kind, because it looks fine in the audit table.

### 4. Multi-material, if the part uses more than one filament

- **Split the colour into its own body and export it in place**, rather than leaving the region to be hand-painted in the slicer. Painting is fiddly and irreproducible; the split is exact and regenerates from the same source. The parent gets the recess, the child is the plug, and loading both at the original origin interlocks them with no gap.
- **Say how to import them**: both files selected together, loaded as a single object with multiple parts, positions preserved. Importing one at a time centres each on the plate and silently loses the alignment.
- **Give the expected colour-change count** as the check on all of that. If the slicer reports more, a part dropped to the plate instead of staying in place.
- **On a cosmetic first layer, prefer the smaller contrast jump.** Each swap takes the nozzle off the visible face, purges, and comes back; a moderate jump makes any bleed forgiving, a light-on-dark one puts the re-entry mark on the surface the object is judged by. Say where the prime tower goes if plate space is tight.
- Two layers of inlay is a few grams of purge, not a reason to avoid multi-material. Price the change honestly before inheriting a spec's blanket "no AMS."

### 5. Deliverables

- Printable STL(s), bed-ready
- The parametric source
- A `README.md` in the part's folder: what it is and how it works · files table · key-dimensions table · material and slice settings · hardware list with real specs (thread standard, head diameter, countersink angle — cite the standard) · install steps · **the home-verification checklist**, kept as a round in `measurements.md` and linked from the README rather than copied into it
- A render or preview good enough to see the part in situ
- **A 1:1 test coupon, for any print that is long, one-shot, or irreplaceable.** A small tile at full thickness carrying the risky features — the same inlay, the same taper, the same first layer — costs a few grams and fifteen minutes against hours of an object there is only one chance at. Export it from the same source so it can't drift.
- **A coupon ladder varies one thing.** Every other risky feature on it is left off or set to its loosest value; otherwise one failing feature blocks every rung and the variable under test never gets tested. Include one rung known to pass, as a control. For press fits, step about 0.02 mm around the starting value; 0.05 steps are too coarse to land a fit. Test the retention feature on its own coupon, after the clearance is settled.
- **When a coupon fails, ask whether I can modify the one in hand** (deburr a lip, shave a rung, ream a hole) to get the answer before you design a reprint. The JONAXEL fit was settled that way, with no second coupon.
- **N identical parts: say how many to print first, and what result clears the rest.** Usually one, whenever the part carries a feature that hasn't been printed yet, with the specific test (press the head in and shake it). I shouldn't have to ask.

The **slice settings** are a real deliverable, not a line item: layer height and why features land on its boundaries, walls and shells, brim, plate type and plate position (including any printer exclusion zone), first-layer speed, orientation with a *do not rotate* if the model is mirrored for it, filament mapping, and the pause height for embedded hardware. Only the rows that differ from the profile default, each with its reason.

**Order the physical tests by which result can still change a file.** A test whose only possible outcomes change a different part is not a gate on this one — and when there is a deadline, the long-pole print goes first, so a failure arrives with time to reprint rather than after an evening spent on the small parts. The real gate is usually the two-minute one: a paper template on the actual site.

The **home-verification checklist** is the important one when I'm designing away from the object. One fill-in bullet per dimension I have to check with calipers, each naming the parameter it drives and what to change if it's wrong. Coupon and first-article results get the same treatment: one bullet per rung or check, with the outcomes to choose from (`→ won't enter / thumb-press / snug / loose`). Include every dimension the design is *sensitive* to — especially any clearance under ~10 mm, which is where a design silently dies.

STEP files, dimensioned drawings and a 1:1 printable drilling template are **not required**, but a drilling template is the highest-value optional artifact for anything that gets screwed to a wall. Offer it; build it if I say yes.

### 6. Release discipline

- **Keep a revision table in the part README, one row per revision, each naming what changed, why, and who asked for it.** The revision *label* is what stops a rev C part shipping with a rev B review; the *table* is what makes a decision legible a week later, when the only remaining question is why the obvious-looking option was rejected. Write the row when the change goes in, not at closeout.
- **One revision label.** If we revise, regenerate *everything* from the parameters in the same pass — source, exports, renders, README, review. A build whose geometry is revision C and whose README is revision B is a trap, and it happens most often when a long run is interrupted partway.
- If you run out of budget or context mid-release, **say which artifacts are current and which are stale** before you stop. That one sentence is the difference between a recoverable handoff and a silent inconsistency.
- Archive the superseded version, or keep it exportable from the same source behind a `variant=` switch — the second is better, since it keeps one file authoritative.

### 7. Closeout

Close out with: where the files live, anything outside the folder you touched, and what is still unresolved (which `measurements.md` items are still blank). **Do not print before the home-verification checklist is done** — say so plainly and stop there.

### Reference instances

**Magnetic photo-album cover, 2026-09-08 → 09-11**. Sixteen revisions, and the useful thing is that almost none of them were taste. Four (D, E, N, O) were the adhesive line — the recess referenced to the rim instead of the insert's back left the tape compressed 0.05 mm over 70 % of the area, and the perimeter was a dry hard stop exactly where a bonded panel peels. Two (H, I) were full rebuilds because the build started on nominal stock while the real sheets and tape were days from being calipered; the measured numbers differed enough to move the rib, the border and the taper. One (M) scrapped a printed panel over engraved alignment marks on the cosmetic face — "why are there grooves on the front face?" — which no geometric check would ever have caught. Two (G, P) were the pin artwork, found by rendering the set together and looking at it. What held: the assertions, the parametric variants, and the 7.5 g coupon that de-risked a 47.6 g one-shot print.

**JONAXEL caster adapter, 2026-11-07**. Prints: coupon A, one rev B puck, three rev C. The rev A puck was never printed. The build took the spec's snap lip and its strain math on trust. Coupon A put that lip on all four clearance pockets, so the head entered none of them. It gave data only after I deburred the lip off: 0.20 drove the bolt but was loose, and the 0.10 rung became the rev B fit. Rev B worked, a touch loose; rev C went to 0.08. Coupon B, a finer lip-less ladder, was built and never needed. The spec-calculation, one-variable coupon, modify-before-reprint, print-one-first and drop-in-vs-press lines, and § Measured fits in `prints/README.md`, come from this one. What held: the audit, the measure-first exception for yes/no checks, and the revision table.

**eero Pro 6E wall mount, 2026-09-07.** Codified from the three-way model comparison. The printability gate exists because one run shipped an undeclared 89 mm bridge and 19.7 cm² of >70° overhang under a "No supports, do not rotate" instruction. The driver-access check exists because it had to be raised manually three times across two runs — and because the one model that encoded it as an assertion never needed telling. The release-discipline section exists because a run that had correctly regenerated and re-verified all its geometry ran out of credit before rewriting its prose, and shipped revision C's part with revision B's review.
