Repository navigation
Composable scroll case components and versioned styles (educelab.v1, villa.2026-10) - #2
Merged
Merged
Conversation
Replace the flat case flags with typed sections ([split], [shell], [ends], [mount], [stand]) and resolve configs as dataclass defaults, then a named style preset, then user values. educelab.v1 is the current design and the permanent default; golden files in tests/presets freeze each released preset. Invalid component combinations are rejected when the config loads. No geometry change: generic, fully featured, solid/65 mm, and PHercParis3 builds match the previous outputs exactly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Model the split as a profile y = f(x) extruded in Z, shared by the mesh and B-rep stages (split.py). `split.type = "curve"` is villa's two-arc S, spanning the whole case to the shell mid-wall so no flat seam lines up with the beam during CT; `amplitude` and `flip` tune it. The divider follows the curve at constant thickness, the honeycomb leaves it solid, and nubs sit at (x, f(x), z) with their bases sunk on slopes. Nub positions are now checked against the fitted layout. Plane-split builds are unchanged (baseline outputs identical). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
New component types: shell "none" (lining, divider, and ends only, with the divider ending in round posts), ends "caps" (villa's square bolted caps, ported from upstream's builder code), and mounts "kinematic" (villa's V-slot disc) and "none". The villa.2026-10 preset combines them as upstream does at 7d6a82c. Components mix within the validation rules; the stand now also requires shell ends. The caps match upstream's to 0.1 mm^3. educelab.v1 builds are unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
scripts/villa_reference.py builds upstream's case bodies in villa's pinned environment and records their volumes and bounding boxes; test_villa_reference.py requires ours to match. At four scroll sizes the symmetric difference between our bodies and upstream's is 0.000 mm^3. docs/villa-2026-10-comparison.md also reports an end-to-end comparison on PHercParis3/4, and corrects the stated effect of upstream's looser cylinder-fit tolerance (0.1-0.2 mm of radius on real scrolls). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Config mistakes raise ConfigError, which the CLI prints as one line (exit 2). Values are type-checked on load, missing files and bad TOML are reported, and the split amplitude is checked before building. Nub errors say which way a nub misses the divider, or that it can't fit. Build failures print the worker's last error line; -v shows everything. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Engrave the left label on -Y when there is no mount disc - Build marker rings on solid shells; ignore them with no shell - Leave a wall's margin between caps and a shell wider than the mount - Reject cap mounting holes that don't fit on the cap Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Case design features are now composable components, and a style is a named, immutable preset over them. Two styles ship:
educelab.v1(default, permanent): today's honeycomb case, unchanged.villa.2026-10: ScrollPrize/villa's scrollcase at7d6a82c. No shell, curved split, square bolted caps, kinematic disc.[split]plane,curve(villa's S, spanning the whole case;amplitude,flip)[shell]honeycomb,solid,none[ends]shell(floor + lid),caps(villa's square bolted caps)[mount]generic-112.5,generic-65,kinematic,noneComponents mix freely, e.g. villa's caps and kinematic disc around a honeycomb shell on a curved split. Combinations that can't be built are rejected when the config loads.
Commits
tests/presets/freeze each released preset. The config schema changes (no compatibility shim);examples/generic.tomlis updated.split.pydefines every split as a profile y = f(x), shared by the mesh and B-rep stages. That keeps undercut removal along ±Y valid. The curve spans the case through the shell wall, so no flat seam lines up with the beam during CT. The divider follows it, the honeycomb leaves it solid, and nubs sit at (x, f(x), z). Nub positions are now checked against the fitted layout.villa.2026-10. Caps are ported from upstream's builder code. New rule: the stand requires shell ends.scripts/villa_reference.pyruns upstream's code in its pinned environment;test_villa_reference.pyrequires our bodies to match its volumes and bounding boxes.docs/and deployed to GitHub Pages frommainby.github/workflows/docs.yml, with a strict build check on PRs. The villa comparison stays in the repo but is left off the site. The README is rewritten to match the repo.examples/template.toml, shown on the "Creating a scroll case" page.test_examples_loadchecks that every example config loads.shell.type = "none"they're ignored instead of rejected, so switching a preset to no shell doesn't also require turning them off. This is documented under[shell].wall_thicknessmargin so the shell isn't tangent to the cap sides. Caps without a shell, includingvilla.2026-10, are unchanged.Smaller commits: config errors are reported without tracebacks, and a
CLAUDE.mdis added.Verification
villa.2026-10case bodies and upstream's is 0.000 mm³.docs/villa-2026-10-comparison.md):Test plan
uv run pytestmkdocs build --strict(CI)🤖 Generated with Claude Code