A Comparison of LLMs for UML State Diagrams Generation

Read full text
Authors: Martina Basic, Marko Vujasinovic
Cited by: 2
References: 6

Abstract

Large Language Models (LLMs) are becoming an increasingly important tool in the field of software engineering, particularly in the automation of UML model creation based on requirements described in natural language. This paper examines the effectiveness of applying LLM technologies to generate UML 2.5 state diagrams in PlantUML format from textual system descriptions. The creation of state diagrams traditionally requires a strong understanding of the problem domain and experience in formal modeling, and it is often a time-consuming and error-prone process. The automated generation of UML state diagrams requires models to correctly identify system states, transitions between states, events, guard conditions, as well as entry, exit, and internal activities, while adhering to the syntax and rules of UML 2.5 notation. In the evaluation part of the study, three systems of varying levels of complexity were analyzed in order to assess the models’ ability to produce syntactically correct and semantically complete diagrams. Additionally, the impact of different prompt design strategies on the quality of the generated results was examined. The results indicate that LLMs can effectively generate state diagrams for simpler systems and significantly reduce the effort required for initial modeling. However, for more complex systems, issues were observed in the consistent interpretation of requirements, the modeling of hierarchical structures, and the preservation of system semantics. Overall, LLM technologies represent valuable support in the early stages of UML state diagram development; however, the final quality of the models still largely depends on expert validation and additional guidance provided by domain specialists.

Fields of Study & Subjects

Model-Driven Software Engineering Techniques Software Engineering Techniques and Practices Business Process Modeling and Analysis

Publication details

Journal / source
International Journal of Innovative Science and Research Technology (IJISRT)
Publisher
International Journal of Innovative Science and Research Technology
Pages
3134–3134
Publication date
13 March 2026