ResearchTrend.AI
  • Papers
  • Communities
  • Events
  • Blog
  • Pricing
Papers
Communities
Social Events
Terms and Conditions
Pricing
Parameter LabParameter LabTwitterGitHubLinkedInBlueskyYoutube

© 2025 ResearchTrend.AI, All rights reserved.

  1. Home
  2. Papers
  3. 2503.08161
50
0

OASIS: Order-Augmented Strategy for Improved Code Search

11 March 2025
Zuchen Gao
Zizheng Zhan
Xianming Li
Erxin Yu
Haotian Zhang
Bin Chen
Yuqun Zhang
Jing Li
ArXivPDFHTML
Abstract

Code embeddings capture the semantic representations of code and are crucial for various code-related large language model (LLM) applications, such as code search. Previous training primarily relies on optimizing the InfoNCE loss by comparing positive natural language (NL)-code pairs with in-batch negatives. However, due to the sparse nature of code contexts, training solely by comparing the major differences between positive and negative pairs may fail to capture deeper semantic nuances. To address this issue, we propose a novel order-augmented strategy for improved code search (OASIS). It leverages order-based similarity labels to train models to capture subtle differences in similarity among negative pairs. Extensive benchmark evaluations demonstrate that our OASIS model significantly outperforms previous state-of-the-art models focusing solely on major positive-negative differences. It underscores the value of exploiting subtle differences among negative pairs with order labels for effective code embedding training.

View on arXiv
@article{gao2025_2503.08161,
  title={ OASIS: Order-Augmented Strategy for Improved Code Search },
  author={ Zuchen Gao and Zizheng Zhan and Xianming Li and Erxin Yu and Haotian Zhang and Bin Chen and Yuqun Zhang and Jing Li },
  journal={arXiv preprint arXiv:2503.08161},
  year={ 2025 }
}
Comments on this paper