ChatPaper.aiChatPaper

DeepCodeSeek: コンテキストを考慮したコード生成のためのリアルタイムAPI検索

DeepCodeSeek: Real-Time API Retrieval for Context-Aware Code Generation

September 30, 2025
著者: Esakkivel Esakkiraja, Denis Akhiyarov, Aditya Shanmugham, Chitra Ganapathy
cs.AI

要旨

現在の検索技術は、標準的なRAGクエリ-ドキュメントアプリケーションに限定されています。本論文では、必要なAPIを予測するためのコードとインデックスを拡張する新技術を提案し、自動補完やエージェントAIアプリケーション向けの高品質なエンドツーエンドのコード生成を直接可能にします。我々は、現行のコード間ベンチマークデータセットにおけるAPI漏洩の問題に対処するため、実世界のServiceNow Script Includesから構築した新しいデータセットを導入し、コード内でのAPI使用意図が不明瞭な課題を捉えます。評価指標によると、この手法は87.86%のトップ40検索精度を達成し、下流のコード生成を成功させるために必要なAPIを含む重要なコンテキストを提供します。リアルタイム予測を可能にするため、合成データセット生成、教師ありファインチューニング、強化学習を通じてコンパクトな0.6Bリランカーを最適化する包括的なポストトレーニングパイプラインを開発しました。このアプローチにより、我々のコンパクトなリランカーは、より大規模な8Bモデルを上回りながら、2.5倍のレイテンシ削減を維持し、大規模モデルの計算オーバーヘッドなしに企業固有のコードのニュアンスを効果的に扱うことができます。
English
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.
PDF31October 1, 2025