Research
AutoBrep: Autoregressive B-Rep Generation with Unified Topology and Geometry
Overview Research area: Computer Vision / 3D generative modeling applied to Computer-Aided Design, specifically direct generation of Boundary Representation (B-Rep) solid models. Technical level: Adva
- arXiv
- 2512.03018
- Published
- 2025-12-02
- Authors
- Xiang Xu, Pradeep Kumar Jayaraman, Joseph G. Lambourne, Yilin Liu, Durvesh Malpure, Pete Meltzer
AI summary
Overview
Research area: Computer Vision / 3D generative modeling applied to Computer-Aided Design, specifically direct generation of Boundary Representation (B-Rep) solid models.
Technical level: Advanced. The paper assumes familiarity with autoregressive Transformers, vector/discrete quantization, and CAD topology (vertices, edges, loops, faces).
Scope: The paper introduces AutoBrep, an autoregressive Transformer that generates CAD B-Reps by encoding both geometry and topology into one unified stream of discrete tokens, and evaluates it on unconditional generation and user-controlled B-Rep autocompletion (published at SIGGRAPH Asia 2025 Conference Papers; arXiv:2512.03018v1).
What This Paper Is About
B-Rep is the standard data structure CAD systems use to define solid models, but generating valid B-Reps directly with precise geometry and watertight topology has remained hard. Prior direct-generation methods relied on multiple separate neural networks trained in stages, which causes error accumulation and makes scaling difficult. AutoBrep instead represents a whole B-Rep as a single sequence of discrete tokens and generates it with one autoregressive Transformer using next-token prediction.
Key Contributions
- Unified tokenization scheme. A tokenization that encodes both B-Rep geometry and topology as a single sequence of unified discrete tokens, combining latent geometry tokens for surfaces and curves with special topological reference tokens for face-edge incidence.
- Single autoregressive Transformer. One model trained with next-token prediction for direct B-Rep generation, reported to achieve higher quality than multi-stage diffusion while giving a 2x to 5x inference speedup and a simplified training pipeline.
- Scalability to complex B-Reps. Generation beyond the 50 faces used by the baselines, while maintaining a higher fraction of valid and watertight B-Reps.
- Native B-Rep autocompletion. Because user-provided faces are treated as a level in the same unified representation, autocompletion is natively supported with guaranteed preservation of the user-provided faces.
Main Findings
- Unconditional generation quality. AutoBrep reaches 71.49% COV, 1.45 MMD (x10^2), 0.97 JSD (x10^2), 99.8% Novel, 93.7% Unique and 70.8% Valid. BrepGen, retrained on ABC-1M, reaches 67.41% COV, 1.91 MMD, 3.50 JSD, 99.7% Novel, 94.5% Unique and 46.6% Valid. HoLa, also retrained on ABC-1M, reaches 67.80% COV, 1.62 MMD, 2.86 JSD, 99.8% Novel, 95.3% Unique and 54.8% Valid. DTGBrepGen, evaluated with its published model (marked with an asterisk), reports 59.39% COV, 1.60 MMD, 1.47 JSD, 64.3% Valid, with Novel and Unique not reported.
- Fastest inference. Averaged time per face for valid B-Reps is 0.46 seconds for AutoBrep, versus 1.25 for BrepGen, 1.68 for HoLa, and 0.69 for DTGBrepGen. Timing was done on a g5.12xlarge instance on AWS with an Nvidia A10G GPU, including post-processing and rebuild time.
- Watertightness at scale. AutoBrep has the highest averaged valid ratio, 70.8%. It maintains roughly 50% valid ratio for solids up to 100 faces, while baselines struggle with validity as face count increases.
- Local topology references beat global ones. Removing the local context window and using a global reference (AutoBrep global) degrades almost all metrics (68.09% COV, 1.58 MMD, 1.03 JSD, 65.3% Valid).
- Breadth-first traversal order matters. Ordering the sequence by sorted face bounding-box coordinates (AutoBrep coord) substantially hurts performance (66.28% COV, 1.53 MMD, 1.61 JSD, 63.6% Valid), with the notably higher JSD indicating deviation from the ground-truth distribution.
- FSQ outperforms VQ codebooks. With the same Deep Compression AutoEncoder backbone and identical latent dimension and codebook size, FSQ achieves the lowest RMSE (0.075 for faces, 0.154 for edges, x10) and 100% codebook usage. VQ-VAE gives 0.473 face RMSE at 99.9% usage and 0.339 edge RMSE at 98.5% usage; the VQ-restart variant gives 0.338 face RMSE at 100% usage and 0.286 edge RMSE at 99.3% usage.
- Lower perplexity on complex solids. AutoBrep achieves the lowest perplexity on Random (2.98), Medium (2.94) and Hard (2.88) complexity data; the coordinate-ordering variant yields the highest perplexity on almost all levels (3.29 Random, 3.35 Medium, 3.31 Hard).
- Autocompletion works with exact preservation. The model generates surrounding geometry and topology that connects to user-provided faces, exactly matching specified assembly interfaces, which the paper states is not possible with prior work.
- Documented failure modes. Self-intersections when many faces are packed in narrow volumes, incorrectly generated screw threads (faces long and winding in one direction, narrow in the other), and thin shells with artifacts from quantization precision and sliver faces.
Methodology in Plain English
The authors treat a CAD solid like a sentence to be written one token at a time.
- Represent geometry as point grids. Each B-Rep face is sampled as a 32x32 grid of points in the parameter domain of its underlying surface, and each edge as a 32-point 1D grid (N = 32 in all experiments).
- Compress grids into discrete tokens. A Deep Compression Autoencoder compresses each face point grid into a 2x2x4 latent grid and each edge grid into a 2x4 grid. Finite-scalar quantization with levels [8,5,5,5], giving a codebook size of prod(L) = 1000, rounds those continuous latents into integer tokens. Compared with BrepGen's 4x4x3 embeddings per face, this is a denser compression that shortens the sequences the Transformer must generate.
- Fix the UV-origin ambiguity. The same surface can be parameterized with the (u_min, v_min) origin at any of four grid corners. Rather than using D2-equivariant convolutions as UV-Net did, AutoBrep lexicographically sorts the four corner points by x, y, z and flips the grid so the lowest-sorted corner is the origin.
- Order faces by graph traversal. The B-Rep face adjacency graph is walked breadth-first, starting from the bottom-leftmost face for unconditional generation, and emitting each new face, then the edges that connect it back to already-visited faces. Faces in the same level are sorted by bounding-box coordinates.
- Encode topology as local references. Because breadth-first traversal means an edge can only connect to faces in the previous level or the same level, the model only needs a local window spanning the two most recent levels. Faces inside that window get sequential reference tags T0, T1, ... (200 unique face IDs are allocated, supporting up to 200 faces across two breadth levels), and those tags reset as the window moves.
- Add position tokens. Since point grids are normalized into a [-1,1]^3 box, each primitive also carries a quantized bounding box: [-1,1]^3 divided into 1024 equally spaced bins per axis, producing six position tokens C = [x0, y0, z0, x1, y1, z1]. Each face geometry is 4 tokens, each edge geometry 2 tokens, and the pair [C, G] uniquely defines a primitive.
- Train one Transformer. The base model is a GPT-style Transformer with 16 self-attention layers, 32 heads, a 2048 hidden dimension and 3K context length, using Swish GLU, RMS layer normalization, rotary positional embeddings, flash attention, grouped query attention with 8 key-value heads, and 0.1 dropout, trained with cross-entropy next-token prediction.
- Add controls and stabilizers. Six sentinel tokens mark starts and ends; complexity meta tokens (Easy <25 faces, Medium 25-50 faces, Hard >50 faces, Random) give control. Level-based attention dropout (0.1) randomly masks tokens outside the local window during pretraining to reduce overfitting to long sequences.
- Fine-tune for autocompletion. The model is fine-tuned on ABC-Constraint with user faces placed in the first traversal level, loss applied only on generated levels, and a dummy token T_u marking dangling edges whose face reference is not yet assigned. Training mixes 80% autocomplete with 20% unconditional generation, and 70% detected constraints to 30% random faces, with up to 15% random translation and scaling augmentation to bridge the gap to real user boxes.
- Sample and rebuild. Inference uses top-p 0.9 and temperature 1.0 with half precision and key-value caching; outputs are converted back to B-Rep following BrepGen by fitting B-spline surfaces and curves and sewing them into solids, with face-edge adjacency decoded directly from the topology tokens.
Two datasets were built from ABC: ABC-1M (multi-body files decomposed into about 3.1 million single-part STEP files, deduplicated to about 1.3 million unique solids, split 70%/15%/15% by stratified sampling on face count) and ABC-Constraint (likely user-selected constraint faces, identified as cylindrical bolt holes — concave cylinders whose axis aligns with an adjacent planar face normal — plus planar faces coincident with the solid's axis-aligned bounding box).
Why This Matters
Impact on research. The paper argues that collapsing six modules (as in BrepGen) down to three (two for encoding) into a single autoregressive model removes cumulative cross-module error, simplifies the training pipeline, and makes sequence models naturally scalable to longer B-Reps — an argument supported by the validity-versus-face-count curve and the ablations showing that local references and BFT ordering both matter.
Real-world applications:
- Automating part design in CAD, where a designer specifies assembly interfaces and the model fills in the rest of the solid.
- Assembly-context modeling, since autocompletion guarantees the user-provided faces are preserved exactly in the output.
- Generating diverse design alternatives for a fixed interface, giving designers a range of material-usage and style options before committing.
- Producing precise, watertight solids suitable for downstream simulation and manufacturing workflows.
Industry relevance. The work comes from Autodesk Research and targets the core data structure of commercial CAD. Autocompletion of parts that must attach to existing geometry is a direct match for how real assemblies are designed, and the reported 0.46 seconds-per-face inference cost is relevant for interactive design tools. Code is released at https://github.com/AutodeskAILab/AutoBrep.
Future Directions
- Address failure cases. The authors propose filtering overly complex B-Reps out of training data (for example, threads belong to standard catalog components like bolts) and improving bounding-box precision to handle thin shells, with the longer-term goal of investigating geometry representations beyond point grids for mechanical components.
- Extend conditional control. The paper demonstrates autocompletion from user faces; broader forms of user control over the unified token stream remain an open area.
- Scale further. The reported results cover solids up to 100 faces and 1,000 edges in pretraining; whether the same recipe scales to substantially larger solids is not established.
- Improve post-processing robustness. Because reported failures arise partly from quantization precision, sliver faces, and sewing, better handling of these reconstruction steps could raise validity further — the paper notes OpenCascade's sewing is relatively robust to minor inconsistencies, allowing some non-watertight outputs to still be rebuilt.
Target Audience
Researchers and practitioners in generative 3D modeling, CAD/geometry processing, and computer vision who are familiar with Transformers and B-Rep topology concepts. It is most valuable to those working on direct CAD generation, tokenized 3D representations, or design automation tooling, and to engineers evaluating whether autoregressive sequence models can replace multi-stage diffusion pipelines for structured geometry.
Authors’ abstract
The boundary representation (B-Rep) is the standard data structure used in Computer-Aided Design (CAD) for defining solid models. Despite recent progress, directly generating B-Reps end-to-end with precise geometry and watertight topology remains a challenge. This paper presents AutoBrep, a novel Transformer model that autoregressively generates B-Reps with high quality and validity. AutoBrep employs a unified tokenization scheme that encodes both geometric and topological characteristics of a B-Rep model as a sequence of discrete tokens. Geometric primitives (i.e., surfaces and curves) are encoded as latent geometry tokens, and their structural relationships are defined as special topological reference tokens. Sequence order in AutoBrep naturally follows a breadth first traversal of the B-Rep face adjacency graph. At inference time, neighboring faces and edges along with their topological structure are progressively generated. Extensive experiments demonstrate the advantages of our unified representation when coupled with next-token prediction for B-Rep generation. AutoBrep outperforms baselines with better quality and watertightness. It is also highly scalable to complex solids with good fidelity and inference speed. We further show that autocompleting B-Reps is natively supported through our unified tokenization, enabling user-controllable CAD generation with minimal changes. Code is available at https://github.com/AutodeskAILab/AutoBrep.