arrow
Return

LLM as a Code Generator in Agile Model Driven Development

delete2026-01-01
delete0
PRE
AI
A
Ahmed R. Sadik *
S
Sebastian Brulin
M
Markus Olhofer
A
Antonello Ceravola
F
Frank Joublin
DOI:10.1007/978-3-031-96841-9_10delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
Leveraging Large Language Models (LLM) like GPT-4 in the autogeneration of code represents a significant advancement, yet it is not without its challenges. The ambiguity inherent in natural language descriptions of software poses substantial obstacles to generating deployable, structured artifacts. This research champions Model-Driven Development (MDD) as a viable strategy to overcome these challenges, proposing an Agile Model-Driven Development (AMDD) approach that employs GPT-4 as a code generator. This approach enhances the flexibility and scalability of the code auto-generation process and offers agility that allows seamless adaptation to changes in models or deployment environments. We illustrate this by modeling a multi-agent Unmanned Vehicle Fleet (UVF) system using the Unified Modeling Language (UML), significantly reducing model ambiguity by integrating the Object Constraint Language (OCL) for code structure meta-modeling, and the FIPA ontology language for communication semantics meta-modeling. Applying GPT-4's auto-generation capabilities yields Java and Python code that is compatible with the JADE and PADE frameworks, respectively. Our thorough evaluation of the auto-generated code verifies its alignment with expected behaviors and identifies enhancements in agent interactions. Structurally, we assessed the complexity of code derived from a model constrained solely by OCL meta-models, against that influenced by both OCL and FIPA-ontology meta-models. The results indicate that the ontology-constrained meta-model produces inherently more complex code, yet its cyclomatic complexity remains within manageable levels, suggesting that additional meta-model constraints can be incorporated without exceeding the high-risk threshold for complexity.
Keywords:
Model driven development
GPT-4 code generation
Multi-agent ontology
Object constraint language
Cyclomatic complexity

Journal

M
MODEL-BASED SOFTWARE AND SYSTEMS ENGINEERING, MODELSWARD 2024
IF:
0
Papers:
13
Citations:
0

Organization

H
honda motor company
Scholars:
446
Papers: 393
Citations: 0