TRANSMISSION // 2612.04685v1

When benefits software gets the past wrong

Source published

A study of one SNAP policy model finds that late entries, repeated corrections and code that bypasses dated rules can distort past-month calculations. In a small test, an AI coding agent did not alter earlier results.

AI-generated conceptual illustration for When benefits software gets the past wrong
AI-generated conceptual illustration; not documentary evidence.

Benefit rules change, but people may need decisions reviewed months or years later. A study of one open-source SNAP calculator examines how its dated rules were maintained—and whether an AI coding agent changed answers about earlier months.

A benefits calculator may be asked about a month long after the rules for that month have changed. To answer correctly, it needs more than today’s rules: it must preserve which rules applied when. A study of PolicyEngine-US, an open-source model of US tax and benefit rules, asks how its Supplemental Nutrition Assistance Program (SNAP) records changed during 2026—and whether an AI coding agent tasked with adding rules would inadvertently rewrite the past.

How the researchers checked

The author examined changes to SNAP’s dated policy values in the project’s code repository between January and November 2026. A script compared entries before and after each commit, and the author manually reviewed commits that changed periods already in effect. The paper also describes an audit of SNAP formulas for cases where code reads rules at a fixed date rather than for the month being calculated.

For a separate test, the researcher selected ten real policy changes, removed each from a copy of the code, and asked an AI coding agent to restore it from a short written notice. Each task ran twice: once with the notice alone and once with a sample test the agent could run. The researchers checked household calculations, earlier dated entries and the project’s own tests.

Updates often reached backward

Of 101 commits that changed dated SNAP values, 72 altered a period that had already begun. New entries also often arrived after their effective dates: 616 of 736 were entered late, with a median delay of 157 days. Until a late entry is added, the calculator continues using the previous value, so it can return outdated results for months even if no existing entry was damaged.

Many changes to the past were attempts to fix earlier mistakes. The author classified 33 commits as fixing wrong values or start dates; 29 repaired entries written earlier in 2026. But corrections could introduce errors too. One March edit unintentionally changed four correct Maryland utility-allowance entries, which were restored three days later. In another case, a correction used a faulty official table and was reversed within a week.

The repository’s history shows that Claude was named as a co-author on 89 of the 101 commits touching dated values. That indicates AI assistance was involved, but it does not reveal what the tool wrote, who selected the values or who checked them. The study therefore describes an AI-assisted codebase; it cannot assign particular errors to the AI.

What happened in the agent test

Across 20 test runs, the agent changed no dated entry before the relevant rule change and produced no different household results for earlier months in the checks performed. It also made both requested corrections to past entries. This is a result from a small, controlled test—not evidence that agents generally leave history untouched.

The agent did make three errors, all involving how a rule fit into the existing code rather than its dates. Examples included adding an exemption to one list but missing a second list. The maintainers’ broader tests caught all three; the sample tests written for the tasks did not directly catch the underlying errors. In some cases, those tests influenced the agent’s choice of implementation, but that is not the same as independently detecting a mistake.

A date-aware record is not enough

The formula audit uncovered a separate problem: one SNAP work-requirement calculation read exemption rules as of a fixed date in 2025, even when calculating earlier months. The dated record contained the stepwise history of the exemption age, but this formula bypassed it. In the researcher’s checks, adults aged 51 to 54 were wrongly treated as not exempt in some earlier months, producing a calculated benefit of zero where the law provided an exemption. The project’s existing tests did not expose this issue; three instead expected the formula’s answer.

The paper proposes automated checks: compare previously effective entries before and after each code change, compare formulas’ historical outputs with the dated record, and flag entries added after their effective dates. These checks could highlight suspicious changes, but they do not replace checking policy against authoritative sources. The study itself found that an official table could be wrong for particular entries.

What the findings can—and cannot—show

The work concerns one codebase, one program and part of one year. There was no comparison year without AI assistance, and the commit labels were assigned by one reader. The agent test involved one AI model, one run per task and condition, researcher-written notices, and a benchmark based on the maintainers’ version—which the paper shows is not always correct. The household checks also missed at least one relevant case. The author cautions that the results are observations, not rates that can be generalized to other tools or systems.

This is a preprint, and its claims should be read in that context rather than as settled evidence. PolicyEngine-US is a calculator used for analysis, not an agency system that determines eligibility or payments. The study does not establish how public benefit agencies’ systems behave. Its narrower lesson is that historical accuracy depends not just on careful edits, but also on timely entries, code that uses the right date, and tests that are checked against the law.

Automatically matched by shared topic keywords. These links do not imply that the sources agree or establish a consensus.