The transformation from requirements engineering (RE) into design artifacts presents a valuable opportunity for software development in contexts such as industrial automation. This thesis explores the feasibility of using Natural Language Processing (NLP) through Large Language Models (LLMs) to convert textual requirements into structured outputs, such as Function Block Diagrams (FBDs) in PLCopen XML format. The research aims to mitigate the challenges of manual transformation processes, including inefficiencies, ambiguity, and the growing complexity of software systems.
Leveraging offline, portable, and open-source LLMs, the study evaluates their ability to generate accurate and semantically aligned structured FBD outputs. Experiments were conducted using synthetic datasets with varying levels of complexity and interdependence. Results demonstrate that larger models excel in producing high-quality outputs, particularly when supported by prompt engineering techniques. However, these models face challenges in handling specific nuances. Smaller models, while faster, exhibit limitations in managing complex or ambiguous requirements.
This thesis contributes to the field by providing insights into the practical deployment of AI-driven solutions for RE (NLP4RE), emphasizing the importance of balancing automation with human oversight. The work highlights future research opportunities, including optimizing resource-efficient models, expanding datasets to real-world scenarios, and posting all the code used in public repositories to enhance reproducibility.