代码搜索去偏:超越整体排序性能以改善搜索结果
Code Search Debiasing:Improve Search Results beyond Overall Ranking Performance
AI总结:
本文从分析模型偏见的新视角研究代码搜索,提出一种通用的去偏框架,通过重排序校准搜索结果以缓解偏见,实验证明其能有效减偏并提升整体排序性能。
摘要:
代码搜索引擎是软件开发中的必备工具。许多代码搜索方法相继涌现,它们主要关注代码搜索的整体排序性能。在本文中,我们通过分析代码搜索模型的偏见,从另一个视角研究代码搜索。有偏见的代码搜索引擎尽管展现出良好的整体性能,却会带来糟糕的用户体验。由于不同的开发习惯(例如偏好长查询或缩写),部分程序员会觉得该引擎有用,而其他人可能发现难以获得理想的搜索结果。为了缓解偏见,我们开发了一个通用的去偏框架,采用重排序来校准搜索结果。它可以轻松插入现有引擎,并处理未来发现的新的代码搜索偏见。实验表明,我们的框架能有效减少偏见。同时,去偏后代码搜索的整体排序性能也得到了提升。
英文摘要:
Code search engine is an essential tool in software development. Many code search methods have sprung up, focusing on the overall ranking performance of code search. In this paper, we study code search from another perspective by analyzing the bias of code search models. Biased code search engines provide poor user experience, even though they show promising overall performance. Due to different development conventions (e.g., prefer long queries or abbreviations), some programmers will find the engine useful, while others may find it hard to get desirable search results. To mitigate biases, we develop a general debiasing framework that employs reranking to calibrate search results. It can be easily plugged into existing engines and handle new code search biases discovered in the future. Experiments show that our framework can effectively reduce biases. Meanwhile, the overall ranking performance of code search gets improved after debiasing.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。