Software Quality Assurance (SQA) planning is a proactive process where teams establish policies—such as maximum file sizes or complexity limits—to mitigate risks before they manifest as defects. However, traditional SQA planning often relies on intuition rather than data. While modern AI tools can predict which files are "risky," they frequently act as "black boxes," providing "feature importance" scores (e.g., "this file is risky because of its size") without offering concrete, actionable advice.
The Challenge of SQA Planning
Practitioners face a significant gap in current defect prediction tools. Knowing that a file is risky is only the first step; developers need to know what to do about it. Specifically, they require:
- Actionable Guidance: Should complexity be decreased, or should code ownership be increased?
- Risk Thresholds: In the context of a specific project, how large is "too large"?
As shown in Figure 4, while practitioners recognize the importance of SQA planning, they also find it difficult and time-consuming, often leading to its inconsistent application in practice.
The SQAPlanner Approach
To address these gaps, we present SQAPlanner, an AI-driven approach that generates specific, data-informed improvement plans. SQAPlanner operates in two main phases:
- Defect Prediction: A global Random Forest model is trained on historical project data to identify defective files.
- Rule-Based Explanation: SQAPlanner utilizes a local, model-agnostic technique to generate four types of guidance (G1–G4):
- G1/G2: Explanations of why current practices are risky or non-risky.
- G3/G4: Suggestions on what to avoid or follow to transition a file from "defective" to "clean."
Technical Implementation
SQAPlanner identifies a "neighborhood" of similar files around a target file and uses crossover and mutation techniques to create synthetic data points. By querying the global model and applying the Magnum Opus association rule mining algorithm, it discovers statistically significant "if-then" rules (e.g., If LOC < 29, then the file is likely clean). These rules are then presented via a Bullet Plot visualization, showing actual metric values against discovered thresholds.
Evaluation and Key Results
We evaluated SQAPlanner using a corpus of 32 releases across 9 open-source projects (e.g., Apache Camel, ActiveMQ). The study utilized 65 software metrics spanning code, process, and ownership.
- Effectiveness and Stability: SQAPlanner outperformed baselines like Anchor and LORE in coverage (median 89%) and confidence (median 99%). Crucially, it achieved high stability (median Jaccard coefficient of 0.92), ensuring consistent advice for developers.
- Practitioner Preference: In a survey of software professionals, 80% preferred SQAPlanner’s visualization over existing tools. As illustrated in Figure 5, the generated guidance (G1–G4) was overwhelmingly perceived as useful, important, and worthy of consideration.
- Applicability: Rules generated from previous releases successfully identified ways to decrease risk in subsequent releases for 55%–87% of defective files.
Insights and Limitations
The transition from feature importance to rule-based anchors is the core innovation of SQAPlanner. By deriving thresholds from a project's own history, the tool provides tailored, context-aware advice.
However, several limitations remain. The rules indicate associations rather than direct causality; reducing a file's size may not resolve a bug if the logic remains flawed. Additionally, while the tool performed well on open-source projects, its efficacy in proprietary environments and its long-term impact on developer behavior require further investigation.
Summary updated