DeepCodeSeek: Real-Time API Retrieval for Context-Aware Code Generation
Fuente:
arXiv
Saved in:
| Main Authors: | , , , |
|---|---|
| Format: | Preprint |
| Published: |
2025
|
| Subjects: | |
| Online Access: | |
| Tags: |
Add Tag
No Tags, Be the first to tag this record!
|
| _version_ | 1866915524347166720 |
|---|---|
| author | Esakkiraja, Esakkivel Akhiyarov, Denis Shanmugham, Aditya Ganapathy, Chitra |
| author_facet | Esakkiraja, Esakkivel Akhiyarov, Denis Shanmugham, Aditya Ganapathy, Chitra |
| contents | Current search techniques are limited to standard RAG query-document applications. In this paper, we propose a novel technique to expand the code and index for predicting the required APIs, directly enabling high-quality, end-to-end code generation for auto-completion and agentic AI applications. We address the problem of API leaks in current code-to-code benchmark datasets by introducing a new dataset built from real-world ServiceNow Script Includes that capture the challenge of unclear API usage intent in the code. Our evaluation metrics show that this method achieves 87.86% top-40 retrieval accuracy, allowing the critical context with APIs needed for successful downstream code generation. To enable real-time predictions, we develop a comprehensive post-training pipeline that optimizes a compact 0.6B reranker through synthetic dataset generation, supervised fine-tuning, and reinforcement learning. This approach enables our compact reranker to outperform a much larger 8B model while maintaining 2.5x reduced latency, effectively addressing the nuances of enterprise-specific code without the computational overhead of larger models. |
| format | Preprint |
| id |
arxiv_https___arxiv_org_abs_2509_25716 |
| institution | arXiv |
| publishDate | 2025 |
| record_format | arxiv |
| spellingShingle | DeepCodeSeek: Real-Time API Retrieval for Context-Aware Code Generation Esakkiraja, Esakkivel Akhiyarov, Denis Shanmugham, Aditya Ganapathy, Chitra Software Engineering Artificial Intelligence Information Retrieval Current search techniques are limited to standard RAG query-document applications. In this paper, we propose a novel technique to expand the code and index for predicting the required APIs, directly enabling high-quality, end-to-end code generation for auto-completion and agentic AI applications. We address the problem of API leaks in current code-to-code benchmark datasets by introducing a new dataset built from real-world ServiceNow Script Includes that capture the challenge of unclear API usage intent in the code. Our evaluation metrics show that this method achieves 87.86% top-40 retrieval accuracy, allowing the critical context with APIs needed for successful downstream code generation. To enable real-time predictions, we develop a comprehensive post-training pipeline that optimizes a compact 0.6B reranker through synthetic dataset generation, supervised fine-tuning, and reinforcement learning. This approach enables our compact reranker to outperform a much larger 8B model while maintaining 2.5x reduced latency, effectively addressing the nuances of enterprise-specific code without the computational overhead of larger models. |
| title | DeepCodeSeek: Real-Time API Retrieval for Context-Aware Code Generation |
| topic | Software Engineering Artificial Intelligence Information Retrieval |
| url | https://arxiv.org/abs/2509.25716 |