paperbot · PL 论文追踪

全部论文 待读 收藏

P1 TreeRanker: Fast and Model-Agnostic Ranking System for Code Suggestions in IDEs

TreeRanker:面向 IDE 代码建议的快速且模型无关的排序系统
ASE 2025 40th IEEE/ACM International Conference on Automated Software Engineering (ASE)2025匹配度 5/10 · 论文将LLM用于改进IDE中静态补全的排序,属于AI→PL的交叉,但更偏向开发者工具与代码补全,而非静态分析在ML/Agentic程序中的应用或形式化验证,与核心方向部分相关。引用 1 inbox
Daniele Cipollone, Egor Bogomolov, Arie Van Deursen, Maliheh Izadi
crossref: 2026-09-12

AI 速览

一句话:提出 TreeRanker:将静态补全组织为前缀树并单次贪心解码打分,实现快速、模型无关的补全排序。

Token 级代码补全是现代 IDE 的核心功能,用于向开发者推荐相关标识符与 API。补全候选通常由静态分析产生,但其实际可用性高度依赖排序:正确预测若排在列表深处,几乎不会被用户看到。现有系统多依赖手工启发式规则或在用户日志上训练的轻量机器学习模型,在捕捉上下文信息、跨项目与跨编码风格泛化方面仍有提升空间。本文提出一种新的打分方法,以轻量且模型无关的方式利用语言模型对静态补全候选排序。该方法将所有合法补全组织为一棵前缀树,并通过一次贪心解码遍历收集树上的 token 级分数,从而在无需 beam search、prompt 工程或模型适配的情况下实现精确的 token 感知排序。该方案快速、与架构无关,并兼容已部署的代码补全模型,为在现有 IDE 工具中集成语言模型、提供更智能且响应更快的开发者辅助提供了实用路径。

问题
IDE 中的静态补全候选排序至关重要,但现有基于手工启发式或轻量日志模型的方法难以充分利用上下文并跨项目、跨编码风格泛化。
方法
将所有合法补全组织为前缀树,用语言模型做一次贪心解码以收集树上的 token 级分数,实现无需 beam search、prompt 工程或模型适配的 token 感知排序。
评估
摘要未明确给出具体数据集、指标或量化结果;作者从方法的速度、架构无关性以及与已部署代码补全模型的兼容性方面论证其有效性。
原文摘要(Abstract)

Token-Level code completion is one of the most critical features in modern Integrated Development Environments (IDEs). It assists developers by suggesting relevant identifiers and APIs during coding. While completions are typically derived from static analysis, their usefulness depends heavily on how they are ranked, as correct predictions buried deep in the list are rarely seen by users. Most current systems rely on handcrafted heuristics or lightweight machine learning models trained on user logs, which can be further improved to capture context information and generalize across projects and coding styles. In this work, we propose a new scoring approach to ranking static completions using language models in a lightweight and model-agnostic way. Our method organizes all valid completions into a prefix tree and performs a single greedy decoding pass to collect token-level scores across the tree. This enables a precise token-aware ranking without needing beam search, prompt engineering, or model adaptations. The approach is fast, architecture-agnostic, and compatible with already deployed models for code completion. These findings highlight a practical and effective pathway for integrating language models into already existing tools within IDEs, and ultimately providing smarter and more responsive developer assistance.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@inproceedings{paperbot9370,
  title = {TreeRanker: Fast and Model-Agnostic Ranking System for Code Suggestions in IDEs},
  author = {Daniele Cipollone and Egor Bogomolov and Arie Van Deursen and Maliheh Izadi},
  booktitle = {ASE},
  year = {2025},
  doi = {10.1109/ase63991.2025.00290}
}