Skip to content

feat(terrarium): author JSCAD solids and a tscircuit coupon - #112

Merged
creatifcoding merged 17 commits into
feat/mantis-biomemetics-labfrom
cursor/mantis-jscad-tscircuit-6eb6
Aug 30, 2026
Merged

creatifcoding merged 17 commits into
feat/mantis-biomemetics-labfrom
cursor/mantis-jscad-tscircuit-6eb6

Conversation

@creatifcoding

@creatifcoding creatifcoding commented Aug 23, 2026 •

Copy link
Copy Markdown
Owner

Why

This PR authors the terrarium enclosure in JSCAD and the indexed coupon in tscircuit. Both trees are on the branch. The review catalog is a separate entity. Its components bind generated/ and the tsci dist/ / __snapshots__/ outputs. This PR is not empty.

Official @jscad/svg-serializer fills geom2 black. The first generate pass only projected the envelope, so front.svg, side.svg, and top.svg were filled 250 x 500 slabs. Generate now converts project() outlines to colored path2 and writes a stroked still for every authored solid.

Scope

Write-set is both trees:

  • projects/biomemetics/labs/mantis/terrarium/cad/jscad/**
  • projects/biomemetics/labs/mantis/terrarium/ee/tscircuit/**

CAD keeps one 250 x 250 x 500 mm envelope, origin front-left-bottom, X-right Y-back Z-up. Named solids from PARAMS are B01 24 mm REF cubes and B05/B06 202 x 3 x 427 mm plates. Placement of the plates is UNVERIFIED. Cassette seat is stock + 0.20 mm TARGET, recorded, not a pocket. No packets/ folder. No PACKET.md.

npm run generate writes stroked front, side, and top SVG for envelope, B01-corner-block, B05-view-cassette, and B06-front-door. Envelope keeps front.svg, side.svg, and top.svg. Every solid also writes {solid}-{view}.svg. generated/VIEWS.md lists each file. B01 is one unique 24 mm cube. The eight instance origins are recorded in VIEWS.md. Pocket cuts and gasket Z are omitted.

EE authors index.circuit.tsx. Native tsci outputs live under dist/ and __snapshots__/. packet/ is gone. No packet.json. No pointer field. B19, B27, B44, B48, S1, S2, Q1, and P01–P12 are BOM balloons compiled on this coupon. They stay UNVERIFIED. There is no admit-list. B19 pads stay omitted. S1, S2, Q1, and B44 pin2 stay NOT_CONNECTED. MPNs stay blank.

Does not write skill files. Does not touch leftover FreeCAD/OCCT, KiCad, S00–S11, packages/lab-ui, specimendb, assistant/, or procurement. PR 34 and PR 36 stay emit. Leftover S00–S11 stay extract. Merge stays held. No Gerber. No orders. No tsci push.

CAD

solid balloon modeled
enclosure envelope — cuboid [0,0,0]→[250,250,500]
B01-corner-block B01 24 mm REF cube, eight envelope corners
B05-view-cassette B05 202 x 3 x 427 mm plate
B06-front-door B06 202 x 3 x 427 mm plate

Recipe is extrusions.project, geom2.toOutlines, closed path2.fromPoints, colors.colorize([0, 0, 0, 1], path), then svgSerializer.serialize({unit: 'mm'}, ...paths). Generate never passes geom2 to serialize. Class generated, not shop-release. In-house print is FDM on Bambu. Printer model is UNVERIFIED.

EE

artifact path command
Circuit JSON ee/tscircuit/dist/index/circuit.json tsci build --disable-parts-engine
Readable netlist ee/tscircuit/dist/readable-netlist.txt tsci export -f readable-netlist
glTF / GLB ee/tscircuit/dist/coupon.gltf, coupon.glb tsci export -f gltf / -f glb
Check stdout ee/tscircuit/dist/check-*.txt tsci check
Schematic / PCB / 3D ee/tscircuit/__snapshots__/index.circuit-*.snap.{svg,png} tsci snapshot --update --3d

Tradeoffs

Official serializer sets root stroke-width="0.1px". Large plates read as hairlines in a small preview. B01 (24 mm) is easier to see. We did not invent a second SVG writer or copy leftover OCCT stroke-width.

Blast radius

Reviewers of the terrarium CAD and EE trees. No existing caller imports these packages. Merge stays held.

Verification

CAD, this revision: npm run generate, npm test, and npm run typecheck exited 0 in terrarium/cad/jscad. Thirteen tests passed. generated/B05-view-cassette-front.svg is width="201.9999mm" height="426.9998mm" with stroke="rgba(0,0,0,1)" and no fill="black". generated/front.svg stays the 250 x 500 envelope outline.

EE, prior revision: tsci build, tsci snapshot --update --3d, tsci export, and tsci check exited 0. npm run typecheck and npm test exited 0. Eight tests passed.

Stroked generate stills: envelope, B01, B05, B06 fronts

Open in Web Open in Cursor 

cursoragent and others added 7 commits August 23, 2026 18:49
TypeScript JSCAD now authors the locked 250 x 250 x 500 mm envelope.
The calculated animal-clear box stays a keep-out because PARAMS does
not lock its Z origin. STL and STEP emit throw. FreeCAD remains emit.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
One tscircuit coupon compiles B27, B50, B44, and B48 through
@tscircuit/core to Circuit JSON. Manufacturer part numbers stay
blank. KiCad remains emit. Gerber is later.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
Official tscircuit/skill wants tsci search, then TSX, then tsci build.
Search did not admit a B27, B50, B44, or B48 series, so MPNs stay
blank and those parts stop as UNVERIFIED. The parts engine is off.
Circuit JSON is the artifact. Gerber and tsci push stay later.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
tsci check, snapshot, and export wrote Circuit JSON, schematic and
PCB SVGs, a 3D PNG, glTF, GLB, and a readable netlist. Check stills
are the CLI stdout. No Gerber, KiCad, S08, or invented MPN.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
tsci export writes <source>.circuit.json next to the entry. The committed Circuit JSON is packet/circuit.json.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
npm run generate uses extrusions.project and @jscad/svg-serializer to write front, side, and top SVG. Class generated, not shop-release. PNG/iso left blank after regl-renderer demo-cli missed @jscad/img-utils.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
Local FDM path on Bambu. Printer model UNVERIFIED. Filament and printed solids stay REF. Packet remains DRAFT ahead of shop outreach 2026-08-25.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
cursoragent and others added 6 commits August 23, 2026 19:44
PARAMS-named solids only. B01 is a 24 mm REF cube from frame.band with eight envelope-corner instances. B05 and B06 are 3.00 mm acrylic plates on calculated clear W x H. World plate placement stays UNVERIFIED. Envelope bbox unchanged. SVG generate re-run.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
PACKET.md records what this tree actually has: envelope bbox, generate SVGs, B01/B05/B06, and the Bambu DRAFT note. Leftover S00-S11 stay extract.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
The review packet is a catalog entity owned elsewhere. This tree keeps generated SVG, TypeScript solids, tests, README, and VIEWS.md.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
User is mid-fork. Restore the existing note without expanding it. Nothing depends on it. It is not the CAD system. No packets/ folder.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
User pick is final. No packets/ folder and no PACKET.md. Generated SVG, VIEWS.md, TypeScript solids, tests, and README stay.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
Delete packet/. Circuit JSON, readable netlist, glTF/GLB, and check stdout now live under dist/ from tsci build/export/check. Schematic, PCB, and 3D snaps stay in __snapshots__/ from tsci snapshot.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
@cursor cursor Bot changed the title feat(terrarium): author solids in JSCAD and boards in tscircuit feat(terrarium): author JSCAD solids and a tscircuit coupon Aug 23, 2026
cursoragent and others added 4 commits August 23, 2026 20:14
B19, B27, B44, B48, and B50 are BOM balloons compiled on this coupon. They stay UNVERIFIED.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
Official svg-serializer fills geom2 black. Generate now converts
project() outlines to colored path2 so each authored solid writes
a stroked front/side/top SVG a person can read.

Co-authored-by: digicoder <creatifcoding@users.noreply.github.com>
@creatifcoding
creatifcoding marked this pull request as ready for review August 30, 2026 02:01
@creatifcoding
creatifcoding merged commit fec13a7 into feat/mantis-biomemetics-lab Aug 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants