AUTO-GENERATION OF UML SEQUENCE DIAGRAMS FROM NATURAL LANGUAGE REQUIREMENTS USING GPT-4 MODEL

Authors

  • Ji Yong Loo Department of Software Engineering, Faculty of Computer Science and Information Technology, Universiti Malaya, 50603 Kuala Lumpur, Malaysia
  • Moon Ting Su Department of Software Engineering, Faculty of Computer Science and Information Technology, Universiti Malaya, 50603 Kuala Lumpur, Malaysia Corresponding Author

DOI:

https://doi.org/10.22452/

Keywords:

UML Sequence Diagram Generation, Software Requirement Engineering, Software Design, Large Language Model, GPT, Natural Language Processing (NLP)

Abstract

Automating the generation of Unified Modelling Language (UML) sequence diagrams from software functional requirements (FRs) can improve productivity. However, existing methods often require user intervention and therefore are not fully automated. To address this gap, this research proposed a novel LLM-based method for automating the generation of UML sequence diagrams from FRs written in English for the web application domain, without requiring human intervention. The proposed method leverages OpenAI’s Generative Pre-Trained Transformer-4 (GPT-4), extracts key information from FRs and constructs corresponding PlantUML statements, which are rendered into UML sequence diagrams. A proof-of-concept prototype implementing the proposed method was developed. The correctness of the artefacts generated by the prototype was evaluated by calculating cosine similarity between them and ground truth (“oracle”) created by third-party experts. An average similarity score of 86.14% across 10 FR sets was obtained, demonstrating a high level of correctness of the generated artefacts. This result shows the potential of LLM, particularly GPT-4 in automatically generating UML sequence diagrams from English FRs.

Downloads

Published

2026-04-30

How to Cite

AUTO-GENERATION OF UML SEQUENCE DIAGRAMS FROM NATURAL LANGUAGE REQUIREMENTS USING GPT-4 MODEL. (2026). Malaysian Journal of Computer Science, 39(2), 110-133. https://doi.org/10.22452/

Similar Articles

1-10 of 409

You may also start an advanced similarity search for this article.

Most read articles by the same author(s)