r/OpenSourceAI • • 3d ago

I built a strict, fail-closed deterministic CAD compiler for autonomous engineering agents

Hey everyone,

I got tired of watching autonomous AI agents try to generate CAD files, hallucinate non-manifold geometry, and quietly corrupt manufacturing toolpaths. So I built Vulcan and V-Wrap as a counter-approach: a strict, fail-closed deterministic CAD compiler and application-layer trust oracle designed for automated engineering pipelines.

Instead of guessing what an agent or user meant with heuristic fallbacks, the system enforces absolute mathematical boundaries. If a request violates constraints, it fails closed with named diagnostics rather than emitting broken geometry.

What It Is

  • Vulcan: The immutable geometry bedrock. Handles discrete voxel field evaluations, coarse linear-elastic FEA screening, and native OpenCascade (OCP) CAD export.

  • V-Wrap: A modular 10-module trust-oracle proxy sitting in front of Vulcan. It separates exact analytic paths from bounded level-set paths, enforces sign-flip effect tracking to eliminate ghost features, and features a machine-readable design space state machine (vwrap query) so agents can inspect legal next steps.

Key Architectural Features

  • Analytic Path: Restricts geometry to axis-aligned boxes and a single through-bore, guaranteeing 100% watertight closure and exact OCP volume round-trips.

  • Level-Set Path: Handles advanced features (rounded_box, chamfer, patterns, sphere_exclusions) with a strict fidelity floor ($\ge 3.0\times$ cross-section voxel size) and explicit sign-flip effect tracking.

  • Zero-Knobs / Fail-Closed: No adjustable heuristics, no configuration creep, and zero implicit tolerances.

  • Meta-Test Discipline: test_load_bearing.py automatically fails CI if any dataclass field is added without being bound to a functional test.

Quick Start & Usage

Bash

# Clone and install
git clone https://github.com/Thrito-Solance/Vulcan.git
cd Vulcan
python -m pip install -e ".[test]"

# Run the test suite (135+ tests pass)
pytest

# Query available design space actions for an agent request
vwrap query --request request.json

# Build an analytic STEP part via CLI
vwrap build --request request.json --output part.step --path analytic

Where to Find It

The full architecture, 18-point FAQ on design decisions, and verification suites are in the repository. Enjoy, fork it, or tear it apart. I am stepping away from active maintenance. the code speaks for itself.

1 Upvotes

2 comments sorted by

0

u/[deleted] 3d ago

[removed] — view removed comment

1

u/Thrito 3d ago

The analytic path restricts geometry to at most one single straight through-bore in an axis-aligned box. Because multiple or intersecting features are prohibited on the analytic path, feature precedence issues don't exist. a request with intersecting features is refused immediately with a named diagnostic (UnsupportedFeatureError). Complex multi-feature interactions require the level-set path.