一句话:构建仓库级定向输入生成基准 RepoEval,并提出智能体工作流 AgenticDIG,使目标覆盖率较最佳基线提升 43.56%。
定向输入生成(DIG)旨在自动构造能到达指定程序位置的输入。已有工作显示大语言模型在函数级 DIG 上有效,但能否泛化到真实仓库级场景尚不清楚:仓库级任务需推理长调用链、项目特定输入语义及分散的执行条件。本文构建跨主流语言的基准 RepoEval,收集难以覆盖的目标行,并在不同上下文与输出设置下评测多个先进 LLM。结果显示仓库级 DIG 显著更难,模型仅覆盖 16.02%–37.35% 的目标,且受仓库语义约束、上下文、输出格式与外部执行条件影响。作者进而提出 AgenticDIG 智能体工作流,融合目标导向分析、意图抽取、故障注入与迭代反馈,目标覆盖率较最佳基线提升 43.56%。
Directed Input Generation (DIG) aims to automatically construct an input that reaches a specified target program location. Although recent studies have shown promising results for Large Language Models (LLMs) in function-level DIG, it remains unclear whether such effectiveness generalizes to realistic repository-level testing scenarios. Unlike function-level settings, repository-level DIG requires reasoning over long call chains, project-specific input semantics, and complex execution conditions distributed across real software repositories. To address this gap, we present a comprehensive empirical study of repository-level directed input generation with LLMs. Specifically, we construct a benchmark, RepoEval, containing hard-to-cover target lines across mainstream programming languages, and evaluate multiple state-of-the-art LLMs under different context and output settings. Our results show that repository-level DIG remains substantially more challenging than prior simplified settings. While advanced models can cover a portion of targets (from 16.02% to 37.35%), their effectiveness is strongly compromised by repository specific semantic constraints, context settings, output formats, and external execution conditions. Based on these findings, we design AgenticDIG, an agentic workflow that integrates target-oriented analysis, intention extraction, fault injection, and iterative feedback to improve repository-level DIG. Evaluation shows that AgenticDIG improves target coverage by 43.56% relative to the best baseline.
@inproceedings{paperbot12512,
title = {From Function to Repository: Towards Understanding and an Agentic Approach for Repo-Level Directed Input Generation},
author = {Haoyu Wang and Ming Wen and Haoran Yan and Jiayi Huang and Xuanhua Shi and Hai Jin},
booktitle = {ASE},
year = {2026},
doi = {10.1145/3832783.3837537}
}