arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2603.22048cs.SE
收藏

动态分析增强问题解决

Dynamic analysis enhances issue resolution

Sun Yat-sen University(中山大学)

Mingwei Liu, Zihao Wang, Zhenxi Chen, Zheng Pei, Yanlin Wang, Zibin Zheng

AI总结:

本文提出DAIRA框架,通过动态分析提升代码缺陷修复效率,实现高准确率和低资源消耗。

摘要:

解决复杂代码缺陷仍是一个软件工程难题。最近,大型语言模型(LLMs)推动了基于代理的自动修复系统的发展。然而,现有方法在处理复杂缺陷如复杂的多态控制流和隐式类型退化时存在困难。这些方法依赖静态分析和浅层执行反馈,无法监控中间执行状态。因此,代理常陷入推测探索,消耗大量令牌而无法找到根本原因。本文引入DAIRA(动态分析增强的问题解决代理),一种将动态分析深度嵌入代理决策循环的新型自动修复框架。DAIRA采用测试追踪驱动的工作流程,利用轻量工具捕获运行时证据(如调用栈和变量状态),并将其转换为结构化的语义报告。通过照亮执行路径和因果依赖,DAIRA实现了精确的故障定位,并防止了无关代码检索导致的上下文窗口溢出。这使代理的方法从推测推理转向确定性推理。在SWE-bench验证基准上的评估显示,当使用Gemini 3 Flash Preview时,DAIRA达到79.4%的修复率。此外,它在解决深层逻辑缺陷方面表现出鲁棒性,在最困难的任务中达到44.4%的修复率。与基线相比,DAIRA独特地解决了复杂边缘案例,并提高了操作效率。在各种LLM上,它将推理成本降低了约10%,输入令牌消耗降低了25%。

英文摘要:

Resolving complex code defects from natural language descriptions remains a fundamental software engineering challenge. Recently, large language models (LLMs) have driven the creation of agent-based automated repair systems. While improving repository-level problem-solving, current methods struggle with complex defects like intricate polymorphic control flows and implicit type degradation. These approaches rely on static analysis and shallow execution feedback, lacking the ability to monitor intermediate execution states. Consequently, agents often fall into speculative exploration, consuming significant tokens without identifying the root cause. We introduce DAIRA (Dynamic Analysis-enhanced Issue Resolution Agent), a pioneering automated repair framework deeply embedding dynamic analysis into the agent's decision loop. DAIRA employs a Test Tracing-Driven workflow, using lightweight tools to capture runtime evidence (e.g., call stacks and variable states) and convert it into structured semantic reports. By illuminating execution paths and causal dependencies, DAIRA enables precise fault localization and prevents context window flooding from irrelevant code retrievals. This shifts the agent's approach from speculative reasoning to deterministic inference. Evaluations on the SWE-bench Verified benchmark show DAIRA achieves a state-of-the-art 79.4% resolution rate when powered by Gemini 3 Flash Preview. Furthermore, it demonstrates robustness in addressing deep-seated logical defects, securing a 44.4% resolution rate on the most demanding tasks. Compared to baselines, DAIRA uniquely resolves complex edge cases and improves operational efficiency. Across various LLMs, it reduces inference costs by approximately 10% and input token consumption by 25%.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑