AI 中文总结
研究针对仓库级文档 README 错误,提出不一致驱动技术 READU,通过高召回率提交过滤器、并行一致性检查器等方法,能即时检测并修复错误,在六个流行仓库的提交测试中表现良好,检测到多个真阳性并成功修复部分错误。
AI 中文摘要
仓库级文档(如 README)通常是用户与仓库的首个接触点。文档错误会导致用户遇到运行时错误或浪费调试时间,我们称此类错误为 README 错误。解决 README 错误具有挑战性,因为文档包含代码且与事实源联系松散。本文提出 READU,一种不一致驱动的技术,用于即时检测和修复 README 错误。READU 的关键在于 README 错误常表现为文档与事实源(如仓库内部的源代码或外部依赖)之间的不一致。它应用高召回率提交过滤器,并行运行内部和外部一致性检查器,使用警报判断去除误报,并自动合成文档补丁。在来自包括 Linux 和 Spring Boot 在内的六个流行仓库的 6000 次近期提交上,READU 以 75%的精度检测到 244 个真阳性,平均每次提交成本低于 0.01 美元且耗时不到一分钟,其中 217 个被正确修复。我们报告了 66 个发现的 README 错误,其中 44 个已确认,26 个已修复。
英文摘要
Repository-level documentation, such as READMEs, is often the first point of contact between users and a repository. When this documentation is incorrect, users may encounter runtime errors or waste their time debugging. We call such mistakes in repository-level documentation README bugs. Addressing README bugs is challenging because documentation mixes prose with code, its connection to the source of truth is loose, and finding a bug still leaves developers to craft a repair. This paper presents READU, an inconsistency-driven technique for just-in-time detection and repair of README bugs. The key insight behind READU is that README bugs often manifest as inconsistencies between documentation and another source of truth: either repository-internal facts, such as source code, or repository-external facts, such as external dependencies. READU applies a high-recall commit filter, runs internal and external consistency checkers in parallel, uses an alert judge to remove false positives, and automatically synthesizes documentation patches. On 6,000 recent commits from six popular repositories including Linux and Spring Boot, READU detects 244 true positives with 75% precision, while consuming less than $0.01 and less than one minute per commit, on average. Of these true positives, READU correctly repairs 217. We report 66 found README bugs, of which (so far) 44 are confirmed and 26 are fixed.