Kogler, PhilippFalkner, AndreasSperl, SimonDhungana, DeepakLambers, LeenBonorden, LeifHenning, Sören2024-02-142024-02-142024https://dl.gi.de/handle/20.500.12116/43507Recent pre-trained Large Language Models (LLMs) have demonstrated promising Natural Language Processing (NLP) and code generation abilities. However, the intrinsically unreliable output due to the probabilistic nature of LLMs imposes a major challenge as validity can generally not be guaranteed, making subsequent processing prone to errors. When LLMs are used to translate natural-language specifications to formal specifications, this limitation becomes evident. We propose a framework involving prompting and algorithmic post-processing that continuously interacts with the LLM to ensure strict syntactic validity and reasonable content correctness. Furthermore, we introduce a use-case in the domain of engineering processes for railway infrastructure and demonstrate that our approach is sufficiently mature for implementation in an industrial environment.enGenerative AILarge Language ModelsReliable Code GenerationPost-processingDomain-specific LanguagesEngineering ProcessesReliable Generation of Formal Specifications using Large Language ModelsText/Conference Paper10.18420/sw2024-ws_10