EventsThe 1st International Online Conference on CivilEng
Published
This submission belongs to the session S1. Mathematical Models for Civil Engineering of the event The 1st International Online Conference on CivilEng
Published date
09 Nov, 2026
Academic Editor
author-avatarAngelo Luongo
Citation
Luigi Altieri, Matteo Torzoni, Stefano Mariani, Topology optimization of truss structures: A large language model-based approach, in Proceedings of The 1st International Online Conference on CivilEng, 12 November–13 November 2026, MDPI: Basel, Switzerland
Share
Email
Facebook
Twitter
LinkedIn

Topology optimization of truss structures: A large language model-based approach

image
image
1. Department of Civil and Environmental Engineering, Politecnico di Milano, Piazza L. da Vinci 32, 20133 Milano, Italy
Abstract

Topology optimization of truss structures is a constrained problem in which traditional methods often face high computational cost and slow convergence. This work investigates a Large Language Model (LLM)-based framework for optimizing truss layouts to maximize structural stiffness under prescribed loading conditions. The optimization problem is reformulated as a sequential design process, where truss configurations are assembled step-by-step following predefined grammar rules to ensure structural feasibility. Each design is represented symbolically as a sequence, enabling the application of LLMs. Specifically, a GPT-2 architecture is trained using a mechanically-informed loss function, in which training samples are weighted according to structural stiffness, thereby achieving structural optimization implicitly. This guides the model toward high-performing solutions while preserving diversity in the design space. The approach is assessed on six benchmark problems characterized by varying seed configurations and loading conditions. The generated structures achieve between 82% and 100% of the corresponding global optimum stiffness. In doing so, the model generates novel and mechanically sound topologies not observed during training. Although LLMs were originally developed for natural language processing, these results suggest that their architecture can be leveraged for engineering design, positioning LLM-based generative frameworks as complementary tools for exploring large and complex design spaces in structural optimization.

Keywords
Large Language Models
GPT
Structural Optimization
Truss Synthesis
Grammar-Based Design
Aerodynamic Loading on Agrivoltaic Systems under Downburst Winds: A Multi-Scale CFD Approach
Assessing Climate-Responsive Public Transport Accessibility in Riyadh: A GIS-Based Seasonal Buffer Analysis