Enhancing Large Language Models with Retrieval Augmented Generation for Software Testing and Inspection Automation

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Fingleton, Zoe, Siavash, Nazanin, Moin, Armin
Format: Preprint
Published: 2026
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866915940717821952
author Fingleton, Zoe
Siavash, Nazanin
Moin, Armin
author_facet Fingleton, Zoe
Siavash, Nazanin
Moin, Armin
contents In this paper, we focus on automating two of the widely used Verification and Validation (V&V) activities in the Software Development Lifecycle (SDLC): Software testing and software inspection (also known as review). Concerning the former, we concentrate on automated test case generation using Large Language Models (LLMs). For the latter, we enable inspection of the source code by LLMs. To address the known LLM hallucination problem, in which LLMs confidently produce incorrect outputs, we implement a Retrieval Augmented Generation (RAG) pipeline to integrate supplementary knowledge sources and provide additional context to the LLM. Our experimental results indicate that incorporating external context via the RAG pipeline has a generally positive impact on both test case generation and code inspection. This novel approach reduces the total project cost by saving human testers'/inspectors' time. It also improves the effectiveness and efficiency of these V&V activities, as evidenced by our experimental study.
format Preprint
id arxiv_https___arxiv_org_abs_2604_15270
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle Enhancing Large Language Models with Retrieval Augmented Generation for Software Testing and Inspection Automation
Fingleton, Zoe
Siavash, Nazanin
Moin, Armin
Software Engineering
In this paper, we focus on automating two of the widely used Verification and Validation (V&V) activities in the Software Development Lifecycle (SDLC): Software testing and software inspection (also known as review). Concerning the former, we concentrate on automated test case generation using Large Language Models (LLMs). For the latter, we enable inspection of the source code by LLMs. To address the known LLM hallucination problem, in which LLMs confidently produce incorrect outputs, we implement a Retrieval Augmented Generation (RAG) pipeline to integrate supplementary knowledge sources and provide additional context to the LLM. Our experimental results indicate that incorporating external context via the RAG pipeline has a generally positive impact on both test case generation and code inspection. This novel approach reduces the total project cost by saving human testers'/inspectors' time. It also improves the effectiveness and efficiency of these V&V activities, as evidenced by our experimental study.
title Enhancing Large Language Models with Retrieval Augmented Generation for Software Testing and Inspection Automation
topic Software Engineering
url https://arxiv.org/abs/2604.15270