计算机科学 > 人工智能
[提交于 2026年11月28日]
标题:GraphCodeBERT for Cross-Language Code Clone Retrieval through Data-Flow Alignment and Hard-Negative Mining
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读摘要:This paper proposes a GraphCodeBERT adaptation that combines soft data flow alignment with reliability filtered hard negative mining. The alignment component compares variable dependency representations across paired implementations without requiring identical identifiers or graph topology. The mining component excludes known equivalent solutions, retains a mixture of random and challenging candidates, and gradually increases negative difficulty. A reproducible evaluation design separates programming tasks across training, validation, and testing and covers six directed retrieval settings involving Java, Python, and Go. Across the six settings, the joint configuration has mean reciprocal rank 0.814, compared with 0.731 for a matched GraphCodeBERT baseline. Removing alignment reduces this score to 0.786, whereas replacing filtered mining with random negatives reduces it to 0.772. The evaluation framework also addresses retrieval depth, perturbation tolerance, mining contamination, and indexing cost under a fixed candidate protocol. The component comparison separates structural supervision from negative selection and identifies their respective contributions to the ranking profile. The resulting design provides an auditable route for investigating whether language independent dependencies and carefully selected distractors improve cross language code retrieval under realistic annotation and computational constraints. The absolute mean reciprocal rank increase is 0.083, corresponding to approximately 11.4% relative to the baseline; this aggregate comparison does not establish statistical significance.
提交历史
来自:Qiong Liu[v1] 2026年11月28日 星期六 14:38:00 UTC (2,948 KB)