LLM-based Iterative Approach to Metamodeling in Automotive
Nenad Petrovic, Fengjunjie Pan, Vahid Zolfaghari, Alois Knoll
TL;DR
The paper tackles the challenge of keeping automotive metamodels aligned with evolving vehicle architectures, which is labor-intensive when done manually. It introduces an iterative LLM-based workflow that uses GPT-4o and Retrieval Augmented Generation (RAG) to generate Ecore metamodels and PlantUML visualizations from OEM requirements, with expert feedback guiding refinement. The prototype, implemented as a Python Flask web service, demonstrates end-to-end artifacts including partial and complete metamodels, updated parsers, XMI instances, and visualization pipelines, plus an optional OCL rule path. A comparative evaluation against a smaller local model shows GPT-4o yields syntactically correct Ecore results, while local models require additional transformations and feedback to reach similar usefulness. The work highlights potential time savings for automotive toolchains and outlines paths toward local deployment and future improvements in evaluation and model correctness.
Abstract
In this paper, we introduce an automated approach to domain-specific metamodel construction relying on Large Language Model (LLM). The main focus is adoption in automotive domain. As outcome, a prototype was implemented as web service using Python programming language, while OpenAI's GPT-4o was used as the underlying LLM. Based on the initial experiments, this approach successfully constructs Ecore metamodel based on set of automotive requirements and visualizes it making use of PlantUML notation, so human experts can provide feedback in order to refine the result. Finally, locally deployable solution is also considered, including the limitations and additional steps required.
