Leveraging Large Language Models for Use Case Model Generation from Software Requirements
Tobias Eisenreich, Nicholas Friedlaender, Stefan Wagner
TL;DR
Problem: manual use-case modeling is time-intensive in requirements engineering. Approach: an open-weight Llama 3.1 70B-based workflow with prompt engineering enables semi-automated extraction of actors and use cases and generation of PlantUML diagrams from textual requirements, with a human-in-the-loop workflow. Findings: in a within-subject exploratory study with five engineers, the method reduced modeling time by about 60% and achieved comparable precision, recall, and F1 to manual approaches; qualitative feedback highlighted usefulness and guidance but noted missing iterative dialogue and traceability needs. Significance: the approach promises substantial efficiency gains and improved stakeholder communication, while highlighting directions for scaling to longer requirements, multi-user collaboration, and enhanced interpretability.
Abstract
Use case modeling employs user-centered scenarios to outline system requirements. These help to achieve consensus among relevant stakeholders. Because the manual creation of use case models is demanding and time-consuming, it is often skipped in practice. This study explores the potential of Large Language Models (LLMs) to assist in this tedious process. The proposed method integrates an open-weight LLM to systematically extract actors and use cases from software requirements with advanced prompt engineering techniques. The method is evaluated using an exploratory study conducted with five professional software engineers, which compares traditional manual modeling to the proposed LLM-based approach. The results show a substantial acceleration, reducing the modeling time by 60\%. At the same time, the model quality remains on par. Besides improving the modeling efficiency, the participants indicated that the method provided valuable guidance in the process.
