arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2407.02883cs.IRcs.CL
收藏

CoIR:面向代码信息检索模型的综合基准

CoIR: A Comprehensive Benchmark for Code Information Retrieval Models

Huawei Noah’s Ark Lab(华为诺亚实验室)

Xiangyang Li, Kuicai Dong, Yi Quan Lee, Wei Xia, Hao Zhang, Xinyi Dai, Yasheng Wang, Ruiming Tang

AI总结:

本文提出COIR代码信息检索综合基准,涵盖七个领域八类任务的十个数据集,并评估九种检索模型,以揭示代码检索难点并推动该领域研究。

摘要:

尽管信息检索(IR)在各种自然语言处理任务中取得了巨大成功,但大多数IR系统主要处理自然语言的查询和语料库,忽视了代码检索领域。代码检索至关重要却仍未得到充分探索,现有方法和基准未能充分体现代码在不同领域和任务中的多样性。为填补这一空白,我们提出了COIR(代码信息检索基准),这是一个稳健且全面的基准,专门设计用于评估代码检索能力。COIR包含十个精心整理的代码数据集,涵盖七个不同领域中的八项独特检索任务。我们首先讨论了COIR的构建及其多样化的数据集组成。此外,我们使用COIR评估了九种广泛使用的检索模型,揭示了即使使用最先进的系统,在执行代码检索任务时也存在显著困难。为便于在现有研究工作流中轻松采用和集成,COIR已开发为一个用户友好的Python框架,可通过pip便捷安装。它与MTEB和BEIR等其他流行基准共享相同的数据模式,支持无缝的跨基准评估。通过COIR,我们旨在推动代码检索领域的研究,提供一个多功能的基准测试工具,鼓励代码检索系统的进一步发展和探索。https://github.com/CoIR-team/coir。

英文摘要:

Despite the substantial success of Information Retrieval (IR) in various NLP tasks, most IR systems predominantly handle queries and corpora in natural language, neglecting the domain of code retrieval. Code retrieval is critically important yet remains under-explored, with existing methods and benchmarks inadequately representing the diversity of code in various domains and tasks. Addressing this gap, we present COIR (Code Information Retrieval Benchmark), a robust and comprehensive benchmark specifically designed to assess code retrieval capabilities. COIR comprises ten meticulously curated code datasets, spanning eight distinctive retrieval tasks across seven diverse domains. We first discuss the construction of COIR and its diverse dataset composition. Further, we evaluate nine widely used retrieval models using COIR, uncovering significant difficulties in performing code retrieval tasks even with state-of-the-art systems. To facilitate easy adoption and integration within existing research workflows, COIR has been developed as a user-friendly Python framework, readily installable via pip. It shares same data schema as other popular benchmarks like MTEB and BEIR, enabling seamless cross-benchmark evaluations. Through COIR, we aim to invigorate research in the code retrieval domain, providing a versatile benchmarking tool that encourages further development and exploration of code retrieval systems. https://github.com/CoIR-team/coir.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑