Code search is an important information retrieval application. Benefits of better code search include faster new developer on-boarding, reduced software maintenance, and ease of understanding for large repositories. Despite improvements in search algorithms and search benchmarks, the domain of code search has lagged behind. One reason is the high cost of human annotation for code queries and answers. While humans may annotate search results in general text QA systems, code annotations require specialized knowledge of a programming language (PL), as well as domain specific software engineering knowledge. In this work we study the use of Large Language Models (LLMs) to retrieve code at the level of functions and to generate annotations for code search results. We compare the impact of the retriever representation (sparse vs. semantic), programming language, and LLM by comparing human annotations across several popular languages (C, Java, Javascript, Go, and Python). We focus on repositories that implement common data structures likely to be implemented in any PLs. For the same human annotations, we compare several LLM-as-a-Judge models to evaluate programming language and other affinities between LLMs. We find that the chosen retriever and PL exhibit affinities that can be leveraged to improve alignment of human and AI relevance determinations, with significant performance implications. We also find differences in representation (sparse vs. semantic) across PLs that impact alignment of human and AI relevance determinations. We propose using transpilers to bootstrap scalable code search benchmark datasets in other PLs and in a case study demonstrate that human-AI relevance agreement rates largely match the (worst case) human-human agreement under study. The application code used in this work is available at \href{https://github.com/rlucas7/code-searcher/}{this github repo}.
LiveCodeBench Pro: How Do Olympiad Medalists Judge LLMs in Competitive Programming?
New York University(纽约大学);Princeton University(普林斯顿大学);University of California San Diego(加利福尼亚大学圣地亚哥分校);University of Washington(华盛顿大学);Canyon Crest Academy(峡谷克雷斯特学院);University of Waterloo(滑铁卢大学);McGill University(麦吉尔大学)
Beyond Memory Leaderboards: Evaluating Scientific Memory as Budgeted Context Restoration
Quantellence Research(Quantellence研究公司);St. Petersburg Department of the Steklov Institute of Mathematics(斯捷克洛夫数学研究所圣彼得堡分部);St. Petersburg State University(圣彼得堡国立大学)
CPRet: A Dataset, Benchmark, and Model for Retrieval in Competitive Programming
The Chinese University of Hong Kong(香港中文大学);Shanghai Artificial Intelligence Laboratory(上海人工智能实验室);Tsinghua University(清华大学);Beihang University(北航);Shenzhen Loop Area Institute(深圳河套学院)
Across Programming Language Silos: A Study on Cross-Lingual Retrieval-augmented Code Generation
Chinese Information Processing Laboratory, Institute of Software, Chinese Academy of Sciences(中国科学院软件研究所中文信息处理实验室);University of Chinese Academy of Sciences(中国科学院大学);The Hong Kong University of Science and Technology(香港科技大学)