scout.

a daily read of the ML and AI papers

SAT · 05 SEP 2026
3 papers

Constraints don't add up.

Three papers on the same blind spot: the code came back, the tests went green, and nobody checked the rest of the instruction. Stack the ordinary constraints a production prompt carries — a JSON envelope, a persona, a note that it is urgent — and correct code falls further than any of them predicted on its own. A third of agent patches that pass a repository's tests violate a requirement a human reviewer had already written down. And a one-line fix arrives as a rewritten function, which no test can object to.

Today's pick
−12.2 pts
how far a JSON-plus-persona-plus-urgency prompt fell below what its three constraints predicted separately, on GPT-4o-mini (percentage points)

Compound Prompt Constraints in LLM Code Generation: A Factorial Study of Format, Persona, and Urgency

Production prompts rarely carry one instruction. They ask for JSON, assign a persona, and mention that the request is urgent — and each of those, tested on its own, looks harmless or mildly helpful. Run all 27 combinations of output format, persona and urgency across 164 coding problems and five models, 22,140 graded runs in total, and the combinations misbehave in a way single-factor testing cannot see: on GPT-4o-mini every one of the eight three-constraint prompts landed below what its parts predicted, the worst 12.2 points below, and a JSON envelope was roughly twice as costly as XML. The vulnerability tracks model family rather than size — both GPT-4.1 models shrug it off, one reasoning model actually improves under a structured-output constraint, and both GPT-4o models suffer. Test the whole prompt you ship, not the constraints one at a time.

221 of 644
agent patches that passed the repository's functional tests and still violated the review requirement they had been given

SWE-Gate: Passing Functional Tests Is Not Enough for Software Engineering Agents

Your agent's patch passes the repository's tests. That is not the bar a human reviewer applies. This benchmark takes requirements from real pull request review comments — which exception type to raise, whether keyword argument order survives, whether re-running the operation twice is safe — and gives each of 303 repair tasks a second test suite for the requirement alongside the usual functional one. Across four models, 644 patches passed the functional tests and 221 of them, 34.3%, failed the stated requirement; even the strongest model hid a violation in 29.5% of its green runs. Putting the requirement in the prompt lifts compliance by 10 to 26 points but lowers the functional pass rate, so the two goals genuinely trade against each other. If you accept agent patches on a green test run, you are accepting about a third of them on a check that never looked.

0.195 → 0.131
excess edit distance beyond the minimal fix, before and after adding one clause asking the model to keep the original code

When Models Edit Too Much: On the Fidelity of Minimal Code Edits

A model asked to fix one bad comparison will often rewrite the function around it, the tests still pass, and nothing flags it. On 400 problems where the correct fix is known to be tiny — half are a single token, none exceeds two lines — frontier models edit far past it, and the cheapest correction is one clause. Appending "keep as much of the original code as possible" cut the excess edit distance from 0.195 to 0.131 across 50 model-and-prompt settings, trimmed the added complexity of the repair by about a quarter, and nudged the pass rate up 2.3 points rather than down; GPT-5.5 gained the most, roughly halving its excess from 0.299 to 0.159. Training the preference in also works, but only reinforcement learning carries it to new bugs: supervised fine-tuning reached 0.932 on the corruption types it had seen and 0.458 on held-out ones, where the reinforcement-trained model held about 0.78 on both.