Parsing Requirements for Automatic Prompting of Large Language Models for Requirements Validation
摘要
Large language models have become very popular. This type of Artificial Intelligence could be a large leap forward toward the automation of software development. The research in this paper is used to semi-automate the engineering processes of class modeling and validation of requirements with structured methods that mitigate the possibility of hallucinations of large language models finding their way into later development. A natural language toolkit is used to learn the specifications and algorithms are made to process the information from the toolkit. The algorithms use the parts of speech tags, constituency information, punctuation, and certain words to select candidate classes for validation and modeling. These candidate classes are added to prompts sent to a large language model with a pre-engineered system prompt to generate the classes in python. The python classes are sent back to the large language model with a second pre-engineered system prompt to produce a python script for modeling and high-level validation. The methods prove successful at providing a path to find a hallucination. The output of the large language model shows perfect consistency when prompted to produce individual classes from the algorithms. The large language model produces validation scripts with moderate to high variability and high to lower usability with the worst scripts taking up to fifteen minutes to correct. The scripts are all usable to automatically generate class models with the free application.