CASCADE: Detecting Inconsistencies between Code and Documentation with Automatic Test Generation
Tobias Kiecker, Jan Arne Sparka, Martin Reuter, Albert Ziegler, Lars Grunske

TL;DR
CASCADE is a tool that detects code-documentation inconsistencies by generating and executing tests from documentation, significantly reducing false positives and uncovering previously unknown issues in open-source projects.
Contribution
This paper introduces CASCADE, a novel LLM-based approach that improves inconsistency detection accuracy by cross-verifying generated tests and code, with practical validation on multiple programming languages.
Findings
CASCADE identified 13 new inconsistencies in open-source repositories.
10 of these inconsistencies were fixed after detection.
CASCADE effectively reduces false positives compared to prior methods.
Abstract
Maintaining consistency between code and documentation is a crucial yet frequently overlooked aspect of software development. Even minor mismatches can confuse API users, introduce new bugs, and increase overall maintenance effort. This creates demand for automated solutions that can assist developers in identifying code-documentation inconsistencies. However, since automatic reports still require human confirmation, false positives carry serious consequences: wasting developer time and discouraging practical adoption. We introduce CASCADE (Consistency Analysis for Source Code And Documentation through Execution), a novel tool for detecting inconsistencies with a strong emphasis on reducing false positives. CASCADE leverages Large Language Models (LLMs) to generate unit tests directly from natural-language documentation. Since these tests are derived from the documentation, any…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
