Abstract
We present TOOLCAD, a framework that augments Large Language Models (LLMs) with programmatic, CAD-specific tools and trains them end-to-end via reinforcement learning for text-to-CAD generation. By letting the model invoke operations such as sketch constraint solving, feature assembly, and parametric history editing, TOOLCAD produces editable, manufacturing-aware B-Rep models directly from natural-language descriptions. Reinforcement learning on tool-aware trajectories substantially improves geometric validity, editability, and user-intent alignment over prior prompt-only or end-to-end SFT baselines, while remaining compatible with any open- or closed-source LLM backbone.
Method · At a Glance
A text prompt enters an LLM agent that interacts with a curated suite of CAD tools (sketching, extruding, filleting, dimensioning, exporting). Each rollout produces a (reasoning, tool-call, B-Rep) trajectory. We optimize the policy with a tool-conditioned RL objective that rewards geometric validity, parametric editability, and semantic fidelity to the prompt.
- Tool-using LLM agent that emits structured CAD operations.
- Reinforcement learning with geometric + editability rewards.
- Text-to-B-Rep outputs that remain editable in standard CAD tools.
Highlights
- First RL framework that teaches LLMs to call CAD tools for text-to-CAD generation.
- Generates editable B-Rep models, not just meshes or point clouds.
- Substantial gains in geometric validity, parametric editability, and intent alignment.
- Plug-and-play with various LLM backbones (open- and closed-source).
Results · Preview
Citation
Acknowledgements
We thank the reviewers and the Shanghai University NLP group for their constructive feedback. This work was supported in part by Shanghai University and its research computing facilities.