- The paper presents a multi-agent framework for closed-loop DFM, integrating LLM reasoning with geometric feature recognition to resolve overhang issues in FDM parts.
- It employs a modular pipeline that combines CadQuery-based geometry parsing, GraphSAGE embedding, and GPT-4o visual verification to enhance defect detection accuracy.
- The study validates its approach on a birdhouse model, demonstrating a 0.75% volume reduction and successful elimination of severe overhangs via automated CAD modifications.
AgentsCAD: Automated Agentic DFM for FDM Parts via LLM Reasoning and Geometric Feature Recognition
Introduction and Motivation
Automated Design for Manufacturing (DFM) remains a persistent challenge for Fused Deposition Modeling (FDM), where manufacturability bottlenecks such as steep overhangs and geometrical defects require expert CAD modifications. While modern slicers can flag defects and propose support structures, translating defect flags into actionable B-Rep geometry modifications is an open research problem. Prior work in LLM-driven CAD has focused on generation and analysis, not closed-loop modification, whereas geometrically-grounded feature extraction systems lack reasoning and modification capabilities. "AgentsCAD: Automated Design for Manufacturing of FDM Parts via Multi-Agent LLM Reasoning and Geometric Feature Recognition" (2607.02448) bridges this gap by presenting a multi-agent framework that integrates explicit geometric reasoning, learning-based semantic labeling, and LLM-driven contextual decision making to autonomously resolve DFM defects in FDM-suitable CAD parts.
System Architecture and Agentic Pipeline
AgentsCAD is built upon a modular, blackboard-based multi-agent architecture orchestrating nine main phases, from geometry parsing to final visual verification. The pipeline is explicitly designed to decouple agents and leverage deterministic, verifiable intermediate artifacts.
Figure 1: The multi-agent flow for automated DFM modification of a CAD part for FDM, highlighting reasoning, verification, and output validation.
- Geometry Parsing and Representation: Input STEP files are traversed using CadQuery and OpenCASCADE, extracting surface type, signed tilt angles (for overhang detection), radius of gyration, elongation index, geometric centroids, and adjacency topologies. This data is compiled into a JSON schema designed for LLM interpretability with each face uniquely identified and topologically contextualized.
- Defect Detection: Deterministic geometric rules flag faces with overhangs above a 45∘ threshold.
- Graph Embedding: A hierarchical GraphSAGE model trained on the MFCAD++ corpus annotates faces with 25-class semantic feature labels and 128D node embeddings. UV-Net-style surface normal augmentation supports richer spatial understanding.
- Reasoning Agent: The Claude Sonnet LLM is responsible for contextual design reasoning, employing chain-of-thought prompting grounded with tooling (MCP tools) to propose global and local modifications. RAG memory modules allow prompt-time injection of relevant past decisions, addressing statelessness and enabling cross-part transfer of DFM heuristics.
- Modification Execution: Recommended design adjustments are programmatically applied using Pythonic CAD APIs, with modifications tracked precisely by face indices.
- Vision-Language Verification: A GPT-4o-based VLM validates the geometric outcomes through rendered composites, answering targeted queries for each recommended operation (e.g., teardrop, fillet, reorientation).
- Output Generation: The pipeline delivers an updated STEP file, recommended changes report, rendered outputs, and a detailed blackboard snapshot for auditability.
This strict phase separation allows deterministic floor establishment for defect detection, leverages verified geometric operations, and trivially supports agent/model/module substitution or extension.
Structured Geometric Representation and LLM Reasoning
Translating high-dimensional, hierarchical CAD geometry into an LLM-consumable yet semantically rich format is non-trivial. The study establishes that flat scalar arrays are too verbose and unstructured for robust reasoning, while classic rule-based systems cannot capture contextuality required for DFM. AgentsCAD’s JSON object representation includes semantic face labels, adjacency lists, feature embeddings, and explicit overhang flags, providing sufficient manufacturing context and topological data for LLM-aided DFM reasoning and action sequence planning.
This approach fundamentally outperforms approaches that operate on geometry in isolation, as topological context is critical for reliable feature recognition and action selection (e.g., distinguishing through-holes from simple overhangs based on adjacency).
Geometric Feature Embedding: GCN vs. GraphSAGE
A rigorous ablation study is conducted, contrasting GCN (transductive, baseline) against GraphSAGE (inductive, aggregation via concatenation) architectures using the MFCAD++ dataset:
- Macro F1 Score: GraphSAGE with UV-net augmentation achieves 0.785 macro F1 and 85% accuracy, outperforming GCN by a significant margin (GCN: 0.469 F1, 53.8% accuracy).
- Effect of Hierarchical Aggregation: For GraphSAGE, moving from V1​ (basic features) to V1​+V2​ (with additional facet-level aggregation) produces the largest F1 boost (+0.182). In contrast, GCN’s performance diminishes with added feature richness, confirming that adjacency-blurring and loss of self-feature information hinders minority-class recognition.
The results highlight that for highly heterogeneous, real-world CAD graphs, inductive, feature-preserving architectures are critical for robust downstream reasoning, especially as richness and complexity scale. Explicit concatenation in GraphSAGE supports rare feature classification and spatial context preservation.
Test Case: Birdhouse Overhang Resolution
AgentsCAD is validated on a nine-face birdhouse model with complex overhanging cylindrical bores:

Figure 2: The original part provided for evaluation in the AgentsCAD pipeline.
Figure 3: CAD input for the simplified birdhouse geometry prior to DFM adjustments.
- The system accurately identifies severe overhangs on horizontal bores in the default Z-up orientation.
- The design reasoner, primed by the RAG pipeline, iterates through orientation proposals, ultimately selecting face_6 as the new build face (X=90∘), aligning the major bore with the build axis to eliminate its overhang.
- The remaining horizontal bore is handled via teardrop modification. The implementation increases face count and reduces overall volume by 0.75%, both validated by the vision-language verifier and by OpenCASCADE’s solid validity checks.
- The visual verifier flags inconclusive render-based deviations, but attributes these to rendering limitations, not actual geometry errors.
This test demonstrates automated, multi-stage reasoning—combining rule-based candidate generation, LLM-driven action selection, and both programmatic and visual model-based validation—in one closed-loop iteration.
Early experiments omitting explicit geometric tool grounding reveal systematic failures in LLM-reasoned geometric transforms, including confident hallucinations of rotation angles and misclassification of overhang statuses. Enabling MCP tools such as check_orientation_overhangs and lay_face_to_build_surface eliminates all such errors, confirming that text-only LLM reasoning over explicit geometry is insufficient for 3D actions, and verified geometric tools are a strict prerequisite for reliable and physically valid modifications.
Implications and Future Directions
AgentsCAD provides an operational demonstration of closed-loop, LLM-driven DFM for FDM, establishing that (a) rich, structured geometric/topological representations are sufficient input for LLM contextual reasoning; (b) inductive graph-based feature embedding is critical for cross-part generalization and rare feature fidelity; and (c) geometric tool grounding is mandatory for reliable reasoning.
Practically, this approach can automate labor-intensive DFM adjustments for FDM workflows, minimize manual iteration between CAD and slicer tools, and serve as a foundation for more advanced, adaptive, or multi-modal CAD modification systems. Theoretically, the blackboard agentic pipeline, modular structure, and RAG-augmented LLM reasoning permit non-parametric, ongoing system improvement, sidestepping the retraining bottleneck.
Anticipated future directions include agent specialization (per-defect-class or DFM type), direct consumption of GNN embeddings in the reasoning prompt, graph-level summarization for large assemblies, and fine-grained integration with GPT-5’s multimodal/3D capabilities. Expansion into assembly handling, defect class broadening, and conversational DFM interfaces represents a logical progression.
Conclusion
AgentsCAD advances LLM-driven design modification from natural language generation and post-hoc validation toward fully autonomous, context-aware, and physically grounded DFM repair for FDM. By integrating graph-based geometric feature recognition, prompt-structured contextualization, and multi-agent orchestration with explicit geometric tooling and multimodal verification, the system closes a crucial gap for industrial additive manufacturing automation. The framework’s extensibility and modularity set a strong trajectory for future research in automated CAD reasoning, DFM optimization, and AI-assisted design engineering.