SieveFL:面向可扩展LLM故障定位的分层运行时感知剪枝
SieveFL: Hierarchical Runtime-Aware Pruning for Scalable LLM-Based Fault Localization
AI总结:
SieveFL通过分层过滤机制提升LLM故障定位效率,通过预处理过滤减少候选方法数量,提升准确率和排名质量,无需使用前沿模型。
摘要:
自动化故障定位需要将观察到的测试失败连接到责任方法,这在数以千计的候选方法中是一个挑战。纯统计方法处理有限,LLM在项目规模上因token成本过高和信号稀释无法处理。我们提出了SieveFL,一个五阶段分层框架,通过激进的预LLM过滤解决这一矛盾。SieveFL将失败测试转换为自然语言失败描述,使用密集向量检索缩小搜索范围到少量可疑文件,然后通过JaCoCo运行时跟踪消除未在失败测试中执行的方法。仅存活的候选者被传递给LLM,LLM逐个检查每个方法并重新排序确认的嫌疑人。我们在Defects4J v1.2.0的395个bug上评估SieveFL,使用中等规模的MoE模型部署在消费级工作站(32GB RAM,8GB GPU)上。SieveFL在12个不完整运行中达到Top-1准确率41.8%(165/395 bugs)和MRR 0.469,优于最强的先前基于代理的基线(AgentFL)2.1个百分点。运行时剪枝减少了79%的候选方法并降低了49%的输入token消耗,同时提高了排名质量:Top-1保持不变,Top-3至Top-10提高2.4个百分点。这些结果表明,通过正确的过滤架构,能够实现有效的故障定位无需使用专有前沿模型。
英文摘要:
Automated fault localization requires connecting an observed test failure to the responsible method across thousands of candidates--a task that purely statistical approaches handle with limited precision and that LLMs cannot yet handle at full project scale due to prohibitive token cost and signal dilution. We present SieveFL, a five-stage hierarchical framework that resolves this tension through aggressive pre-LLM filtering. SieveFL converts a failing test into a natural-language failure description, uses dense vector retrieval to narrow the search to a small set of suspicious files, and then eliminates any method not executed during the failing test via JaCoCo runtime traces. Only the surviving candidates are passed to the LLM, which screens each method individually and re-ranks the confirmed suspects in a single comparative pass. We evaluate SieveFL on 395 bugs from Defects4J v1.2.0 using a mid-sized, openly available MoE model deployed on a commodity workstation (32 GB RAM, 8 GB GPU) via Ollama--no frontier APIs or datacenter hardware required. Treating 12 incomplete runs as failures, SieveFL achieves Top-1 accuracy of 41.8% (165/395 bugs) and an MRR of 0.469, outperforming the strongest prior agent-based baseline (AgentFL) by 2.1 pp in Top-1. Runtime pruning removes 79% of candidate methods and reduces input token consumption by 49%, while simultaneously improving ranking quality: Top-1 is preserved exactly and Top-3 through Top-10 improve by up to 2.4 pp. These results demonstrate that, with the right filtering architecture, capable fault localization does not require proprietary frontier models.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。