Recall Before Rerank: Benchmarking Deep Learning Models for Large-Scale Code-to-Code Retrieval

📅 2026-06-24
📈 Citations: 0
Influential: 0
📄 PDF
🤖 AI Summary
This work addresses the precision and scalability bottlenecks faced by current deep learning models in the initial recall stage over terabyte-scale code corpora, which hinder efficient semantic search and clone detection. For the first time, we systematically evaluate the recall capabilities of large code models on a massive multilingual code dataset and propose a lightweight LLM-driven approach that leverages code normalization and query rewriting to enhance retrieval effectiveness. Experimental results demonstrate that our method substantially improves recall accuracy for lower-capacity models, while also uncovering critical limitations of existing approaches in cross-dataset generalization and deployment under resource constraints. These findings offer practical guidance for building efficient and scalable code retrieval systems.
📝 Abstract
Semantic code search and clone detection are essential for software development, maintenance, and reuse. This paper evaluates the effectiveness, efficiency, and scalability of contemporary deep learning models for first-stage recall in large-scale code-to-code search engines. Benchmarking across multiple programming languages and datasets reveals critical limits in the precision and scalability of these models on Terabyte-scale source-code collections. We present LLM-based code normalisation and query-rewriting schemes that yield significant gains in precision for lower-performing models. Our results question the sustainability of resource-constrained deployment and the assumed robustness of current code-specialised LLMs across datasets. We conclude with actionable insights for building scalable, efficient code-retrieval systems.
Problem

Research questions and friction points this paper is trying to address.

code-to-code retrieval
deep learning models
large-scale benchmarking
recall
scalability
Innovation

Methods, ideas, or system contributions that make the work stand out.

code-to-code retrieval
first-stage recall
LLM-based normalization
query rewriting
scalable code search
🔎 Similar Papers