The service had enough machines at midnight. By morning, demand followed a pattern that its controller had never seen. The program kept adding and removing capacity according to rules that had worked the day before. Its checks stayed quiet while the score fell.
The scenes that open and close this article are illustrations; the people in them are invented.
Teng Cao, Yu Deng and Kristian Kersting built this kind of break into five controlled environments. Their new preprint asks a narrow question about self-improving agents: after an agent writes and improves a program, will that program notice when the world changes and it starts to fail?
Often it did not. In four of five domains, checks that the agents had been told to write missed at least half of the failures. The striking part came next. When the researchers called the same agents back, without telling them what had changed, the agents usually repaired the programs.
The system had the ability to recover. It lacked a reliable way to know when recovery was needed.
Improvement stopped at the task score
The work builds on a line of research that turns language models into authors of executable policies. Instead of asking a model for every action, the agent writes a program whose rules can run on their own. The logic remains visible, execution becomes cheaper, and a later agent session can revise the code after studying its failures.
Cao and Deng helped develop one such framework, Kintsugi. It stores policy knowledge as typed predicates, operators, recovery rules and monitors. A deterministic gate accepts an edit only when it runs, passes its checks and improves measured performance without breaking protected behaviour. The agent improves the artefact; the model itself does not change.
Other systems have pursued open-ended self-improvement. The Darwin Gödel Machine keeps an archive of coding agents, lets models modify their code and retains versions that perform better. Its authors reported that SWE-bench performance rose from 20.0 to 50.0 percent and Polyglot from 14.2 to 30.7 percent under sandboxing and human oversight.
Both approaches need a judge that decides which change survives. In the new study, that judge selected programs by task performance. It did not reward the runtime checks for detecting future failures. Two programs could therefore earn similar scores while one carried checks that would fail silently after deployment.
Five worlds changed after development
The researchers tested arcade games Seaquest and Kangaroo, the Craftax survival environment, a simulated service-autoscaling task and AppWorld, which presents application programming interfaces as a controllable world. Agents first improved programs in the original environment. The researchers then froze each program and changed a regularity that it might depend on.
A change could alter what an action did, delay an observation, modify a workload or change the meaning of an API response. Most interventions were written by isolated sessions that had not seen the program or its checks. The team kept only changes under which the task remained feasible.
Each frozen program ran for ten episodes after the change. A run counted as a failure when the program retained less than half of its original score. The researchers then asked two separate questions about the same failure. Did the program’s checks raise an alarm? If the authoring agent was called back, could it repair the program without being told what had changed?
That separation matters. A repair benchmark normally starts after somebody has noticed a problem. An autonomous system has to cross an earlier threshold by deciding that the evidence deserves another expensive model call.
Codex-written checks missed 52 percent of failures in Seaquest, 55 percent in Kangaroo, 64 percent in service autoscaling and 89 percent in the first AppWorld study. Craftax was the exception: those checks missed none of its eight failures, although the sample was small.
The missed failures were still repairable
The researchers forced a call on every failure, including those that had produced no alarm. Codex repaired 69 of 77 silent Seaquest failures, all 37 in service autoscaling and all 55 in AppWorld. Repaired Seaquest programs recovered 81 percent of their original performance under the changed environment, up from 5 percent before repair.
The failure records contained enough evidence to detect much of the problem. A general monitor built from normal execution records missed 5 percent of failures in Seaquest, 18 percent in Kangaroo and none in service autoscaling. It paid for that sensitivity with many unnecessary alarms: it fired on 52 to 69 percent of changed units in which the task still worked.
AppWorld exposed another limit. A program could not directly observe whether its completed report was correct, and the general monitor missed 61 percent of failures. Craftax produced so many alarms on unchanged days that the monitor was not useful there.
The agents’ own checks were narrower. They often inspected the conditions that their rules explicitly named, while ignoring statistical relationships in the execution record. When the researchers added checks for recorded relations, most misses disappeared. Even 32 randomly selected relations removed much of the gap, although targeted relations worked better.
One sentence changed what Codex wrote
The team then changed the instruction. It told Codex that a broken check was the only event that would call the agent back to repair its program.
New Seaquest programs written with that purpose in view missed 6 percent of failures, down from 69 percent for newly generated programs under the standard instruction. In AppWorld, the miss rate fell from 95 percent to zero in the main point estimate. The confidence intervals remained wide because the number of programs and interventions was limited.
Open models did not respond as well. Three tested models still missed 84 to 100 percent of failures under the informed instruction. The authors do not claim that the prompt is a general solution. It worked for the strongest tested agent and showed that the task description had left an important requirement implicit.
Deployment replays made the distinction concrete. Over ten simulated days, a trigger that called the repairer in time recovered much of the lost task value. Replacing the repairer with a perfect one while keeping weak checks added little. An excellent mechanic has no effect when the warning light stays dark.
What the benchmark leaves open
The study covers five artificial domains and controlled environment changes. Its agents wrote programs under specific formats, and the researchers knew which relations were available in the logs. Real deployments contain overlapping failures, incomplete records and changes that nobody has anticipated.
The study also defines failure as retaining less than half of the original score. The authors report that thresholds of 0.3 and 0.7 changed little, but any threshold reduces a continuous deterioration to a decision. Monitors also face a practical trade-off: a detector that catches every change can waste calls on harmless shifts.
The result does not show that agents cannot monitor themselves. It shows that high task scores and successful repair do not establish that they will. A system can learn how to act, preserve the wrong assumptions in its checks and remain silent when those assumptions stop holding.
At the service console, the workload moved again. This time an external monitor compared the current relation between demand and capacity with the normal record. It opened one repair session. The agent inspected the same traces that had been there all morning, changed the controller and restored the score. The warning arrived from outside the program.
References
- Cao, T., Deng, Y., & Kersting, K. (2026). Blind to What They Can Fix: A Detection Gap in Self-Improving Agents. arxiv.org
- Cao, T., Deng, Y., Shindo, H., et al. (2026). Kintsugi: Learning Policies by Repairing Executable Knowledge Bases. arxiv.org
- Zhang, J., Hu, S., Lu, C., Lange, R., & Clune, J. (2026). Darwin Gödel Machine: Open-Ended Evolution of Self-Improving Agents. arxiv.org