← Back to the workspace

How it's built · built by engineers, for engineers

From a sentence to manufacturable CAD

VayuAI CAD turns a plain-English description into a parametric solid model, exports the real engineering files (STEP, STL, GLB), and produces a true ASME Y14.5 drawing, all without leaving the browser. Here is exactly how the pipeline works.

01 · System

The shape of the system

A thin React frontend talks to a Python backend that owns the geometry. The browser never runs CAD; it renders a lightweight GLB and the generated drawing, while every solid is built, validated, and exported server-side by build123d on the OpenCascade kernel.

The frontend is Next.js + React Three Fiber (a Zustand store, a sectionable 3D viewer with click-to-measure and view presets, a live parameter panel, and the embedded ASME drawing). The backend is FastAPI, exposing generation, parametric edits, hero parts, and a refine-by-chat endpoint.

02 · Generation

Prompt → verified geometry

Generation is not a single model call; it is a closed loop that writes code, runs it through a real CAD kernel, and checks the resulting geometry against what the prompt asked for. If the part fails to build or doesn't match the spec, the error and the measured facts are fed back and the model tries again (up to four attempts).

Before the model ever sees the prompt, select_exemplars() pulls the two most relevant parts from a library of 15 hand-authored, verified build123d modules and few-shots them in, so the model writes in the house style. The system prompt also carries sensible engineering defaults (mm, centered origin, clearance-hole tables) and a design-intent → operation recipe map (slots, bosses, ribs, gears, enclosures, assemblies). Several candidates are generated in parallel and the best verified one wins.

03 · Assemblies

Multi-component models with real checks

Assembly mode generates a component manifest instead of a single solid: each component is a closed body, placed by build123d joints (rigid and revolute frame-to-frame connections, the same idea as Onshape mate connectors) or explicit locations. Joint angles and spacings are named parameters, so editing a dimension re-poses the whole assembly deterministically, with no AI in the loop.

Every build then runs interference detection: an exact pairwise boolean intersection between all components, the same semantics SolidWorks uses. Touching faces count as contact; any positive overlap volume is reported per pair in mm³ and fed back to the model for repair. An assembly is only marked verified when it builds with zero interference. The workspace adds a component tree (hide/isolate/select), a deterministic exploded view, and an ASME Y14.34-style parts list with per-line materials, masses, and CSV export that can seed the sheet nesting planner.

04 · Models

A $0 multi-model router

Code generation runs on a fallback chain of free LLM providers. Each request tries the fastest provider first; on a quota limit or error it falls through to the next, so the product keeps working at no cost. Anthropic is wired in but disabled by default while we stay on free tiers.

05 · Output

What you actually get

Every successful generation produces a complete, downloadable engineering package:

  • STEP - the parametric solid, ready to open in SolidWorks, Fusion, or any MCAD tool.
  • STL - a watertight mesh for 3D printing.
  • GLB - the lightweight model shown in the browser viewer.
  • ASME Y14.5 drawing - orthographic views with dimensions (and a section view where it helps), generated from the same solid.
  • Named parameters - extracted dimensions you can edit live to re-drive the geometry.