In software quality assurance, Just-In-Time Defect Prediction (JIT-DP) and Just-In-Time Defect Localization (JIT-DL) automate the identification of potential defective code and localization of defect lines by analyzing program change characteristics and code commit contexts. These techniques enables just-in-time quality monitoring and defect prevention during development, while also reducing manual costs and improving reliability. Due to the high dynamism and unstructured noise in code change data within agile development scenarios, as well as the difficulty in capturing complex nonlinear synergistic effects of multidimensional expert features, existing work faces dual challenges: lack of data robustness and lack of fine-grained modeling of expert features. To address these challenges, we propose a multi-task interaction technology JIT-DCK , which contains three core components: defect feature preprocessing component, defect prediction component, and defect localization component. The defect feature preprocessing component creates a subword vocabulary, controls extreme values and removes interference to generate data with three aspects, sending the line-level structure to the defect localization component and the semantic aggregation and expert features to the defect prediction component. The defect prediction component is structured with a three-layer cooperative architecture. It works on fusing semantic and line-level features and also models the complex nonlinear relationships of 14-dimensional expert features to achieve effective defect prediction. The defect localization component builds a closed-loop decision chain. It integrates commit-level global features and line-level local semantics through multi-level encoding and dynamic attention mechanisms for accurately localizing defects. Experiments show that JIT-DCK significantly outperforms SOTA models in defect prediction and localization metrics such as F1-Score +2.76%, AUC +1.79%, CodeChurn@20%Recall +2.88%, Top5-Acc +3.10%, Top10-Acc +2.55%, Recall@20%CodeChurn l +6.46%, CodeChurn@20%Recall l +18.58%, and IFA +3.57%, demonstrating its competence in code defect prediction and localization tasks.
Wang et al. (Fri,) studied this question.