- The paper introduces a generative model that leverages autoregressive techniques to synthesize CAD sketches using tokenized geometric primitives.
- It factorizes sketch synthesis into primitive and constraint modeling, achieving robust autocompletion and noise-resilient inference.
- The model enhances design workflows by enabling dynamic sketch autocompletion and scalable constraint inference for automated design refinement.
Vitruvion: A Generative Model of Parametric CAD Sketches
Introduction
The paper "Vitruvion: A Generative Model of Parametric CAD Sketches" introduces a machine learning approach for generative modeling of parametric CAD sketches using autoregressive models. This research aims to enhance the design process by enabling tools like autocompletion, constraint inference, and conditional synthesis, effectively integrating machine learning into modern mechanical design workflows.
Figure 1: CAD sketch generation conditioned on a hand drawing.
The model synthesizes sketches by generating geometric primitives and constraints. These constraints mirror the relational structure fundamental to CAD, capturing a designer's intent and allowing parametric modification. Figure 1 depicts this capability, where a hand-drawn sketch conditions the generation of a computable model.
Methodology
The methodology centers on factorizing CAD sketch synthesis into primitive generation and constraint generation (Figure 2). The process starts with a sequence of geometric primitives, each represented by tokenized parameters. These primitives are subject to constraints that ensure coherence in design alteration.
Figure 2: Factorization of CAD sketch synthesis into primitive generation and constraint generation.
Primitive Model
The primitive model uses a decoder-only transformer to predict sequences of sketch primitives. These take quantitative forms, such as lines or arcs, parameterized by position and type, captured using token embeddings processed through a transformer architecture. Training involves maximizing token sequence log-likelihood, and the model's performance is validated using test set likelihood (Figure 3).

Figure 3: Random examples from the SketchGraphs dataset (left) and random samples from the primitive model (right).
Constraint Model
The constraint model conditions on the primitive sequence to generate the constraint graph—essentially edges in a geometric graph reflecting relational dependencies. Utilizing an encoder-decoder transformer, it refines primitive placements, robust against noise through Gaussian perturbations during training (Figure 4).
Figure 4: Image-conditional samples showing noise-resilient inference.
Evaluation
The model's capabilities extend to autocompleting designs and interpreting sketches from rough hand drawings. Evaluated across various settings—including image conditioning and primer-based generation—the model exhibits significant improvements over baselines in reconstructing precise constraint graphs and maintaining geometric intent through edits.
Autocompletion and Noise Robustness
Exemplifying practical applications, the model's robustness to noise increases real-world applicability. Figure 5 shows improved constraint recovery versus noiseless constraints, capitalizing on augmentation strategies to maintain performance.
Figure 5: Differing results from constraint models trained with and without noise.
Implications and Future Work
The implications of Vitruvion are twofold: it enriches the design process by potentially automating routine tasks in mechanical design, and it offers scalable generative models for constraints in sketch modeling. Future developments may involve expanding the models to 3D datasets or dynamic inputs like 3D scans.
In conclusion, Vitruvion not only illustrates the potential of machine learning in CAD but also provides a framework toward fully integrated design environments supporting intelligent design tools. The research opens pathways for further exploration in efficient, user-driven design automation.