How solidcraft uses parametric CAD and MCP to support verifiable Agent modeling
The author breaks down solidcraft, an open-source pure-Rust CAD project on GitHub, explaining how its B-Rep kernel and 787 parametric CAD commands support desktop, WASM, headless CLI, and MCP environments. The project provides 23 MCP tools, including rollback batch processing, modeling-result validation, and temporary parameter checkpoints, and can export STEP AP242, IGES, 3MF, STL, GLB, and URDF.
By examining solidcraft’s engineering implementation, the article concretely shows how a parametric CAD engine can provide Agents with verifiable, rollback-capable modeling workflows.
The biggest problem with having AI create 3D models has never been rendering quality. It is that meshes generated directly by large models cannot be engineered iteratively—move a screw hole by 2 mm, and the entire model has to be scrapped and redrawn.
The open-source pure-Rust CAD project with 17.6k GitHub stars tangency-labs/solidcraft Cloned it locally and looked through it crates/mcp/src/tools.rs and Cargo.toml; three engineering metrics are especially worth referencing:
1️⃣ Pure Rust zero unsafe(with the workspace enabled unsafe_code = "forbid"): 5,496 items .rs files + 36 core crates + 14 solidcore B-Rep kernel module, 787 parametric CAD commands on desktop (egui+wgpu(), browser (WASM), headless CLI, and MCP through the same engine bus
2️⃣ An anti-hallucination mechanism designed for agents (23 built-in MCP tools):
batchBy default, a transaction can run up to 10,000 commands.rollback: truerollback on all failuresexecute/batchCan be attached.expectfields, immediately comparing the closed volume after modeling (default tolerance 0.2%) and the bounding box (0.05 mm)check_parametersTemporarily create checkpoints to test dimensional changes and measure cylindrical-hole axes before restoring the state, never contaminating the Undo history
3️⃣ 90 groups of mathematical and cross-kernel tests:docs/oracle.md 69 groups of closed-form analytic geometry + 21 FreeCAD comparisons (typical average surface deviation <0.003 mm), directly outputting STEP AP242 / IGES / 3MF / STL / GLB / URDF
Source: verse alan · x.com
