Burr
Burr is a design-rule linter for CAD-as-code workflows.
It checks generated design data and artifacts for mechanical mistakes before they become prints, prototypes, or expensive debugging sessions.
design file -> generated part -> burr-design-data.json -> Burr checks -> receipt
Burr is not a constraint solver, FEA engine, or universal CAD brain. It does not design the part. It checks whether generated CAD violates known mechanical rules.
Why
Image review is useful, but not enough. A screenshot can show that something looks suspicious; it cannot reliably prove exact hole distances, hidden clearances, source/STEP freshness, or rule-specific pass/fail.
Burr turns design data into measurable receipts:
M3 loaded mounting hole
measured center-to-edge = 8.0 mm
required center-to-edge = 10.2 mm
result = fail by 2.2 mm
Install
See INSTALL.md for current crates.io and uv install paths.
For local development:
Install the Rust CLI from crates.io:
Run the CLI from a local checkout:
Run the build123d adapter examples:
The build123d examples commit only design.py. actuator.step and
burr-design-data.json are generated by the example scripts and ignored by git.
Start a build123d part:
Commands
|
|
init creates a minimal build123d project with design.py, pyproject.toml,
and .gitignore. Until burr-build123d is published to PyPI, the generated
project depends on the helper from the burr-build123d-v0.5.0 Git tag.
check finds burr-design-data.json, runs freshness checks and rulepack
checks, then writes burr-receipt.json beside each design data file.
stamp computes sha256 and size_bytes for declared source and generated
artifact files.
Build123d Helper
Burr does not replace build123d. The optional helper records design data while your normal build123d file creates geometry.
=
That one helper call cuts the hole in build123d and records the feature Burr
checks. Burr core still reads only burr-design-data.json, so other CAD tools
can use the same contract.
Design Data
A lintable CAD artifact folder contains burr-design-data.json.
This file is the language-agnostic contract. It can be emitted by build123d, CadQuery, OpenSCAD, JavaScript CAD, Rust CAD, Fusion scripts, or any tool that can write JSON.
Rulepacks
The included actuator mount rule checks loaded M3 clearance holes:
Versioning
Burr has three versioned surfaces:
Burr package version -> CLI/library behavior
Design data schema version -> JSON shape Burr can read
Rulepack schema version -> rule syntax Burr can execute
Receipts include all three:
Unsupported design data or rulepack schemas fail lint instead of silently producing untrustworthy receipts.
Legacy fray-cad.json files with schema fray.cad.artifact.v1 are still read
for transition, but new integrations should emit burr-design-data.json.
Example Result
Bad actuator:
FAIL examples/build123d-actuator/bad/burr-design-data.json -> <not written>
1 problem:
1. M3 loaded hole m3_lower_left is too close to the edge.
Measured center-to-edge: 8 mm
Required center-to-edge: 10.2 mm
Short by: 2.2 mm
Try moving the hole inward or increasing the surrounding part size.
Fixed actuator:
Status
Early prototype. Current checks are design-data-based. Future versions may derive more facts directly from STEP topology.