Papers
Topics
Authors
Recent
Search
2000 character limit reached

Self-Refining Topology Optimization via an LLM-Based Multi-Agent Framework

Published 22 May 2026 in cs.MA | (2605.23273v1)

Abstract: Topology optimization is a widely used design method that produces optimized material distributions for prescribed objectives and constraints through well-established numerical algorithms. Throughout the workflow, engineers make a series of decisions ranging from setting and adjusting numerical parameters to assessing whether the converged design meets considerations beyond those explicitly included in the optimization problem, such as physical feasibility. These decisions, which draw on domain expertise, interfere with the autonomous design process. To address this difficulty, this study presents TopOptAgents, a multi-agent system for automating not only the design process but also decision-making during the key stages of the topology optimization process. TopOptAgents consists of six LLM-based agents collaborating through iterative self-refinement cycles spanning problem formulation, validation, code generation and execution, and quality assessment of the optimized structure. This process enables error correction and progressive improvement of both the optimization setup and resulting design. The framework is demonstrated on optimization problems selected to cover a range of settings that differ in their literature coverage and numerical characteristics The benefits of iterative self-refinement are found to be particularly pronounced for problem classes where the pretrained LLM has limited prior exposure, such as formulations whose literature and open-source implementations are comparatively sparse. In such cases, the proposed framework reliably produces converged designs where a single state-of-the-art LLM struggles, suggesting that self-refinement broadens the range of topology optimization problems that LLM-based automation can reliably address.

Authors (2)

Summary

  • The paper presents a multi-agent system (TopOptAgents) that self-refines topology optimization by decomposing tasks among specialized LLM personas.
  • The methodology integrates role segmentation, conditional context injection, and cyclic error correction to enhance numerical stability and design quality.
  • Empirical benchmarks show significant improvements, notably an 80% success rate for complex L-shaped beam optimization compared to single-pass LLMs.

Autonomous Topology Optimization with LLM-Based Multi-Agent Self-Refinement

Background and Motivation

Topology optimization forms the backbone of computational design for high-performance structures, driven by iterative PDE-constrained optimization, sensitivity analysis, and expert-driven decision-making. Practical adoption is hindered by the need for domain-specific human interventions throughout the workflow, including formulation translation, parameter tuning, structural assessment, and correction of failure modes such as mesh dependencies and numerical instabilities. Existing LLM approaches, while capable of automating code generation and elementary reasoning, fail in handling specification ambiguities and complex design-quality evaluations. Recent advancements in multi-agent LLM frameworks have shown promise in domain-specific automation but lack rigorous mechanisms for error recovery and iterative internal correction, especially for tasks that require multimodal assessment and cross-stage refinements.

TopOptAgents Multi-Agent Framework

TopOptAgents is introduced as a self-refining multi-agent system that automates topology optimization end-to-end, with a clear segmentation of roles and iterative feedback loops at specification, code execution, and design evaluation stages. The workflow decomposes the optimization pipeline into six LLM-based personas:

  • Scientist: Interprets user queries, formulates the mathematical specification, and injects problem-class–specific context as needed.
  • Validator: Examines formulations for consistency, detects errors/omissions, and applies domain heuristics for numerical stability.
  • Planner: Decomposes the implementation strategy into single-function tasks for tractable code generation.
  • Coder/Executor/Reviewer (Code Generation Team): Generates executable Python scripts, manages execution, and iteratively refines based on error traces.
  • Critic: Evaluates multimodal outputs against a four-part rubric (validity, consistency, convergence, design quality), triggering targeted refinements when criteria are not met.

The framework enables cyclical self-refinement across distinct workflow stages, emulates expert reasoning, and automates decision-making beyond code synthesis—addressing design-quality pathologies and specification mismatches invisible in single-pass LLM approaches. Figure 1

Figure 1: Overall workflow of the decision-making and computational processes for topology optimization.

Topology Optimization: Problem Complexity and Parameter Sensitivity

The formulation and execution of topology optimization are sensitive to parameter choices, which often require heuristic adjustment for stable convergence and physically realistic material distributions. Parameters such as filter radius (rminr_{\min}) and projection thresholds (η\eta) critically impact design discreteness, iteration count, checkerboard suppression, and mesh independency. Figure 2

Figure 2: Effect of the filter radius {rmin}\{r_{\min}\} and projection threshold {η}\{\eta\} on convergence behavior and final topologies.

A rigorous automation must therefore reason across both mathematical formulation and empirical parameter selection, accounting for code-level errors and numerical instabilities that arise during iterative execution.

Multi-Agent Workflow Architecture

The agent architecture is configured via structured system prompts specifying detailed role, inputs, instructions, constraints, and output formats, optimized for token efficiency and context relevance. Key architectural innovations include conditional context injection, enabling dynamic adaptation to problem variants with sparse training coverage (e.g., stress-constrained optimization using p-norm aggregation [holmberg2013stress]), and seamless inter-agent memory sharing for stateful refinement. Figure 3

Figure 3: Overview of the TopOptAgents workflow and agent outputs at each stage.

Figure 4

Figure 4: System prompt structure for the Scientist agent, incorporating role, input fields, instructions, rules, and output schema.

The code generation team (Coder–Executor–Reviewer) incorporates iterative error correction based on runtime signals, while Critic agent performs multimodal evaluation using a domain-specific rubric encompassing output completeness, consistency, convergence, and design quality—including detection of checkerboarding and gray regions requiring parameter schedule adjustment. Figure 5

Figure 5: Profiles of the agents in TopOptAgents, summarizing model backbone, task complexity, and token efficiency.

Benchmark Evaluation and Numerical Performance

Three benchmark problems are selected to probe the framework's robustness across a spectrum of representation in pretrained LLM corpora:

  • Cantilever beam compliance minimization: canonical, widely documented.
  • MBB beam variant: moderate coverage, load position rarely documented in the exact form.
  • L-shaped beam stress minimization: minimal coverage, stress constraints and geometric singularities. Figure 6

    Figure 6: Benchmark problem settings and representative user queries.

Success rate and refinement iteration counts empirically demonstrate the value of the self-refinement mechanism:

  • Cantilever problem: both TopOptAgents and single LLM converge successfully with zero refinement.
  • MBB variant: TopOptAgents recovers a 20% performance gap through Validator and Reviewer loops.
  • L-shaped problem: TopOptAgents achieves an 80% success rate (vs. 10% for single-pass LLMs), requiring up to 12 refinement iterations. Figure 7

    Figure 7: Expected self-refinement and retry counts for the benchmark problems.

    Figure 8

    Figure 8: Success rates over 10 trials for benchmark topology optimization problems.

Failure Modes and Self-Refinement Mechanisms

Distinct refinement loops are triggered based on the origin of failure:

  • Validator–Scientist Loop: Specification-level correction (boundary condition mismatches, omitted parameters, singularities). Figure 9

    Figure 9: Validator agent directly corrects external load location in Scientist's initial description.

    Figure 10

    Figure 10: Validator agent requests reformulation for load location overlap with void regions.

  • Reviewer–Coder Loop: Code-level error correction (undefined functions, execution failures, iterative refinement). Figure 11

    Figure 11: Reviewer agent corrects code errors; iterative refinement resolves downstream errors.

  • Critic-Driven Loop: System-level evaluation (design-quality failures, specification mismatches, inadequate filter or projection parameters). Figure 12

    Figure 12: Critic agent identifies constraint/specification errors and boundary inconsistency.

    Figure 13

    Figure 13: Critic agent refines filter radius rminr_{\min} to mitigate checkerboard patterns.

    Figure 14

    Figure 14: Critic agent adjusts beta continuation schedule for enhanced design discreteness.

These loops enable detection and autonomous correction of failure modes that would escape code-level or specification-only checks, particularly those requiring multimodal assessment.

User Interface and Outcome Communication

The system provides a chat interface summarizing agent conversations for transparency, enabling user-initiated further design refinements via follow-up comments that are processed without workflow reset, leveraging shared memory and agent state. Figure 15

Figure 15: Final report generation consolidating problem formulation, code, and evaluation for compliance and stress benchmarks.

Figure 16

Figure 16: Human-in-the-loop feedback, adding structural features (hole) and initiating subsequent refinement cycles.

Theoretical and Practical Implications

TopOptAgents' architecture formalizes expert decision-making in topology optimization as segmented, iterative reasoning procedures, supporting parameter adaptation and multimodal quality control. Practically, this approach expands the range of LLM-handled topology optimization tasks beyond those documented in public codebases or training corpora, with robust recovery of success rates for problems prone to specification ambiguity and numerical instability. Theoretically, it provides a blueprint for domain-specific agentic automation frameworks, blending retrieval-augmented context injection, multimodal rubric-based evaluation, and cyclic error correction.

Future Directions

Scalability is currently limited by the representational capacity of pretrained LLMs and availability of domain-specific context modules. Direct expansion pathways include LLM fine-tuning on topology optimization corpora [prabhakar2025omniscience], retrieval-augmented generation grounded in formal ontologies [stewart2026graphagents, luo2025hypergraphrag], and extension to higher-dimensional topologies and manufacturing constraints.

Conclusion

TopOptAgents demonstrates principled multi-agent self-refinement for autonomous topology optimization, with rigorous handling of specification, code execution, and design-quality pathologies. Empirical evaluation affirms measurable success-rate recovery and robust error correction compared to single-pass LLM baselines, especially on sparse-coverage benchmarks. The multimodal, rubric-driven Critic agent and context-injection mechanisms broaden the scope of reliable task automation. Further progress hinges on targeted model adaptation and ontology-driven retrieval integration for less represented formulations and pathological failure modes.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Collections

Sign up for free to add this paper to one or more collections.

Tweets

Sign up for free to view the 1 tweet with 2 likes about this paper.