CAD-WAM: Anticipating Geometry for Text-to-CAD Generation
Organizations: University of Science and Technology of China · Nanyang Technological University
Abstract
Generating editable computer-aided design (CAD) models from text requires selecting operations that produce the intended changes to the geometry constructed so far. An incorrect operation can compromise subsequent steps, making reliable multi-step generation challenging. Existing methods based on large language models (LLMs) primarily learn to predict commands, without explicit supervision of the geometric states those commands should produce. Inspired by world-action models, we introduce CAD-WAM, which couples geometry-conditioned action generation with next-state prediction. We define complete modeling operations as actions in a CAD domain-specific language (DSL) and encode surface point clouds of intermediate solids into compact latent states using a pretrained variational autoencoder. An LLM backbone generates the next action from the target description and current geometric state, while an auxiliary head on the same backbone predicts the next state to provide geometric supervision during training. We construct step-wise training trajectories from parametric CAD models in the DeepCAD dataset, pairing each trajectory with an expert-level textual description. At inference, each generated action is executed by a CAD kernel, and the resulting solid is re-encoded to inform the next decision. On the DeepCAD test set, CAD-WAM outperforms the task-specific baselines in geometric accuracy and output validity, with larger gains on models requiring more operations, and produces more accurate geometry than general-purpose LLMs prompted with the same DSL. Ablations further show that next-state supervision reduces mean Chamfer distance by 13.2% relative to an otherwise identical model trained only to predict actions. Code is available at https://github.com/Lzy-1037/CAD-WAM.
Figures & tables
| Metric | Text2 CAD | CAD- Coder | CADFS- 8B | Pointer- CAD | cadrille (text) | CAD- WAM (Ours) | Qwen3.8- Flash | DeepSeek V4.1- Flash | GPT-6 Astra | Claude Opus 5.5 |
|---|---|---|---|---|---|---|---|---|---|---|
| IR (%) | 2.627 | 0.741 | 8.125 | 8.800 | 2.529 | 0.666 | 28.360 | 29.478 | 0.025 | 9.068 |
| CD mean median | 12.896 | 3.292 | 4.151 | 2.580 | 3.391 | 1.142 | 3.717 | 3.158 | 1.755 | 3.106 |
| 0.554 | 0.210 | 0.196 | 0.300 | 0.218 | 0.166 | 0.206 | 0.200 | 0.173 | 0.197 | |
| HD mean median | 14.446 | 6.576 | 7.491 | – | 7.365 | 4.134 | 6.634 | 6.304 | 4.728 | 6.354 |
| 5.687 | 3.089 | 3.038 | – | 3.166 | 2.783 | 3.053 | 3.029 | 2.841 | 3.020 | |
| NC mean median | 0.693 | 0.845 | 0.839 | – | 0.836 | 0.903 | 0.854 | 0.860 | 0.888 | 0.859 |
| State | IR (%) | CD | HD | NC | ECD | IoU | Euler match (%) | |||
|---|---|---|---|---|---|---|---|---|---|---|
| mean | median | mean | median | mean | median | |||||
| Latent State | 0.666 | 1.142 | 0.166 | 4.134 | 2.783 | 0.903 | 0.964 | 7.313 | 0.964 | 95.850 |
| Text State | 1.482 | 1.405 | 0.172 | 4.619 | 2.834 | 0.893 | 0.964 | 7.996 | 0.952 | 94.556 |
| Configuration | IR (%) | CD | HD | NC | ECD | IoU | Euler match (%) | |||
|---|---|---|---|---|---|---|---|---|---|---|
| mean | median | mean | median | mean | median | |||||
| w/o State Prediction Head | 0.779 | 1.316 | 0.167 | 4.264 | 2.785 | 0.902 | 0.964 | 7.374 | 0.960 | 95.404 |
| w/ State Prediction Head | 0.666 | 1.142 | 0.166 | 4.134 | 2.783 | 0.903 | 0.964 | 7.313 | 0.964 | 95.850 |
Appendix figures & tables12 assets
Supplementary material from the paper’s appendix.
Appendix
| Field | Type | Meaning |
| kind | string | operation identifier, "extrude" |
| plane.origin | 3 floats | origin of the sketch plane |
| plane.normal | 3 floats | plane normal, along which the profile is extruded |
| plane.x_dir | 3 floats | in-plane direction |
| profile.loops | list | closed loops of lines, arcs and circles |
| forward | float | extrusion distance along the normal |
| Architecture | |
|---|---|
| Backbone | Qwen2.5-1.5B-Instruct |
| Geometric tokens | 16 |
| Slot width | 256 |
| Geometric State Embedding | 2 Transformer layers, 8 heads, feed-forward width 1024 |
| State Prediction Head | mean pooling, LayerNorm, MLP (GELU) |
| Added parameters | 11.4M, or 0.74% of the backbone |
| Models | Records | |
| DeepCAD models | 178,238 | |
| Geometrically verified | 176,226 | |
| With an expert description | 174,582 | 526,010 |
| Training split | 157,945 | 475,656 |
| Validation split | 8,755 | 26,394 |
| Test split | 7,882 | 23,960 |
| System | Outputs | Generation | Attempted |
|---|---|---|---|
| Text2CAD | our inference | single pass | 7,841 |
| CAD-Coder | our inference | single pass | 7,958 |
| cadrille | our inference | single pass | 7,949 |
| CADFS | released results | single pass | 7,212 |
| Pointer-CAD | published results | step-wise | – |
| Qwen3.8-Flash | API | DSL, rendered views | 7,962 |
| Metric | |||||
|---|---|---|---|---|---|
| IR (%) | 0.779 | 0.691 | 0.666 | 0.791 | 0.804 |
| CD | 1.316 | 1.229 | 1.142 | 1.232 | 1.107 |
| HD | 4.264 | 4.203 | 4.134 | 4.163 | 4.184 |
| NC | 0.902 | 0.902 | 0.903 | 0.903 | 0.903 |
| ECD | 7.374 | 7.251 | 7.313 | 7.189 | 7.196 |
| IoU | 0.960 | 0.961 | 0.964 | 0.963 | 0.962 |
Text-to-CAD Generation
Text-to-CAD generation turns natural-language design intent into executable, editable parametric 3D models and assemblies.
See all 49 papers