The Critic Logged Healthy for Weeks and Never Judged Anything
The critic’s log line read:
10 findings, 1 calls
Findings came back. The model call succeeded. No error, no warning, no retry. The lane looked healthy, and it had looked healthy for weeks.
It had never produced a verdict on a single finding.
What the critic was for
Our vulnerability scanner runs deterministic rules first and then hands their findings to a set of model-driven lanes. One of those lanes is a critic. Its job is to read each finding against the code and return a verdict: the issue is reachable, the issue is a false positive, or the issue extends further than the rule saw. Its own instructions said that culling false positives was half of its value.
The verdicts are the point. A verdict feeds the budget for deeper analysis, gives the confirmation step something to confirm, and is the only thing that can mark a finding as a proven false positive. The critic returned findings. It never returned verdicts.
How both were true at once
The critic’s output was declared as a typed schema, and the framework handed the model the generated JSON schema
for it: field names, types, and whatever description each field carried. The list of allowed verdict values lived in a
trailing # comment beside the field in our source code. No field had a description. The prompt described verdicts in
prose and never named the field they belonged in.
So the model was shown a field called verdict, with no type beyond a string and no hint of what belonged in it. It
did the reasonable thing with an unspecified field. It wrote its reasoning into the free-text message field and left
the verdict empty.
From there the silence cascaded. The empty value mapped to nothing, so the verdict became null. The budget step saw no prior opinion on any finding. The confirmation step had nothing to confirm. The predicate that asks “is this a proven false positive?” was never true, and the view of suppressed findings never suppressed anything. Five stages, all gated on one field nobody wrote.
The log line stayed green because it counted what the lane emitted, not what it did. Emitting findings and emitting verdicts are different jobs. Only the first was instrumented.
There was a second blind spot downstream. The adapter that normalised the scanner’s output for our benchmark dropped the verdict field outright, so a run in which the critic adjudicated every test case scored identically to a run in which it adjudicated none. Once the critic was working, we diagnosed it as broken a second time from that output before we found the drop.
What changed
The contract lives where the model reads it. Every field in the schema now carries a description, the verdict field names its exact allowed values, and the instructions carry an explicit output-contract paragraph that names the field. Two channels, both of which the model actually sees.
There are now tests that fail on the class, not just the instance:
- a test fails if an allowed verdict value appears anywhere other than the generated schema;
- a test fails if any field in the schema has no description;
- a test fails if the instructions stop naming the verdict field and its values;
- a test fails if a value the schema advertises does not map to a verdict;
- and a test fails if an empty or unrecognised verdict is coerced into one, because absence must stay absence.
The log counts the work. It now reports how many findings carry a verdict, and it warns when findings arrive with none. The change is two lines, and it would have surfaced the problem on the first run.
A dismissal is now scrutinised, not trusted. A false-positive verdict is the only one that removes a finding, so its failure mode is a missed vulnerability. It is written by a model reading untrusted repository content, and “this is a false positive” is exactly the sentence an injection would try to elicit. A dismissal now escalates for deeper analysis instead of acting as a cheap prior.
The measurement
On the run that exposed it: 10 rows, 0 with a verdict. After the fix: 91 rows, 91 with a verdict.
Then we measured it against a purpose-built evaluation with a control arm: 60 findings known to be false and 30 known to be real. Of the 42 false findings the critic adjudicated, it dismissed 42. Of the 30 real ones, it wrongly dismissed none. One dismissal, as the critic reasoned it:
“(7*42) - num > 200 evaluates to true (208 > 200), so the else branch setting bar to param never executes”
The same day’s record carries its open items next to that number. On a full-size repository the lane still ran out of time and degraded to empty, and end-to-end suppression had not yet been validated. The measurement shows the critic can judge. It does not yet show it judging at scale.
The class
If a model must produce a value, the specification for that value has to live in the schema it is shown. A comment is written for the next engineer. The model is not the next engineer. An undescribed field is an unspecified field, and the model will fill it with whatever it infers, which may be nothing.
The wider failure is not about models at all. A component that emits output while failing at its job looks exactly like a component that is working, if the only thing you count is output. Every lane, job, or service that exists to make a decision deserves a metric that counts decisions, and an alarm for zero.
The line that stays
An output schema is a prompt, and a log line is only evidence about the thing it counts.
Emitting findings and emitting verdicts are different jobs, and only the first was observable.