arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2610.32578cs.SE
收藏

教训长存于失败之外:AI编码智能体规则的案例研究

Lessons Outlive Their Failures: A Case Study of Rules for AI Coding Agents

Hassan Hassanzadeh Aliabadi

AI总结:

本文通过六周案例研究,分析AI编码智能体框架的失败与教训,发现过时文档是主要失败类别,部分教训失效,需定期重新测试并淘汰过时规则。

摘要:

AI编码智能体越来越多地在一套框架(harness)中工作,该框架包含规则文件(如[此处的链接])、按需技能、运行时钩子和自动化检查。大多数关于框架的研究仅关注单一时间点或短期基准运行。本文报告了一项为期六周的案例研究,研究对象是笔者的个人记录系统——一个纯Markdown仓库,三种AI智能体工具在一套共享规则下每日对其进行编辑。笔者记录了118次智能体失败、其修复情况以及失败是否复发;还测试了该系统每月的LLM文档审计,针对47条已知过时陈述和20条植入错误;最后在隔离的git克隆中重放了五次过去的失败,分别在有修复和无修复的情况下进行。所有结果均来自同一仓库,每个条件下三次运行,因此作为探索性结果报告。过时文档(漂移)是最大的失败类别(118次中的48次),尽管其中35次是在某一次审计日发现的。单次审计运行发现了约一半的已知漂移(Claude Sonnet 5.5均值:50%),且其发现中至少93%是正确的。在Sonnet 5.5上,智能体完成了五项重放任务中的四项;在这四项中的三项中,无论是否应用修复,失败均未发生;仅过时计数失败在无检查时复发,而检查在每次运行中均阻止了该失败。在旧模型上,当em-dash lint检查处于活动状态时,智能体曾起草过一次em-dash,该检查拒绝了它;关于运行时估计的书面规则并未改变Sonnet 4.5的高估情况。这些结果表明,框架教训可能长存于其旨在修复的失败之外,而漂移仍然存在,仍需机械检查;演化框架的工具添加教训的速度快于淘汰教训的速度,因此应定期重新测试其规则并淘汰过时规则。

英文摘要:

AI coding agents increasingly work inside a harness: rule files such as AGENTS.md, on-demand skills, runtime hooks and automated checks. Most studies of harnesses look at a single point in time or at short benchmark runs. I report a six-week case study of my personal system of record, a plain-markdown repository that three AI agent tools edited daily under one shared rule set. I built a ledger of 118 agent failures, their fixes and whether they came back. I also tested the system's monthly LLM documentation audit against 47 known stale statements and 20 planted errors. Finally, I replayed five past failures in isolated git clones, with and without their fixes. All results come from one repository with three runs per condition, so I report them as exploratory. Stale documentation (drift) was the largest failure class (48 of 118), although 35 of those were found on one audit day. A single audit run found about half of the known drift (Claude Sonnet 5.5 mean: 50%), and at least 93% of its findings were correct. On Sonnet 5.5, the agent finished four of the five replayed tasks. In three of those four, the failure did not happen, with or without its fix. Only the stale-count failure came back without its check, and the check stopped it in every run. On older models, an agent drafted an em-dash once while the em-dash lint check was active, and the check rejected it. A written rule on run-time estimates did not change Sonnet 4.5's overestimates. These results suggest that harness lessons can outlive the failures they were written to fix, while drift persists and still needs mechanical checks. Tools that evolve a harness add lessons faster than they retire them, so they should re-test their rules from time to time and retire the obsolete ones.

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

↑