Shaurya Singh

← writing

A Scorer Must Fail on Purpose Before It Can Pass for Real

A similarity score isn't trustworthy until it's been shown a case built to fail on each axis it claims to measure — one control per axis, not one adversarial case for the whole score.

ongoing · instrument doctrine

ongoing · instrument doctrine — four axis-isolated controls proven on one identity engine, not yet ported to a second scorer

I run a scorer that outputs one number for “does this rendered face match the reference face.” Seven dimensions go in — jaw, nose, eyes, brow, mouth, proportions, cheeks — weighted and summed, one float comes out. For a while I trusted that float because it looked reasonable. Then I asked it a question nobody had asked it before: if I hand you two faces that are identical except for the jaw, does the number actually move on the jaw axis, or does it just move?

That question has nothing to do with whether the score can be tricked. It has to do with whether the seven numbers feeding the sum are seven numbers at all, or one number wearing seven labels.

One score pretending to be seven

A composite similarity score is an average of things it claims to measure independently. The claim is structural, not cosmetic: jaw/chin worth 20%, nose 18%, eyes 18%, brow 12%, mouth 12%, proportions 12%, cheeks 8%. Each weight is a bet that the underlying feature actually carries information the other six don’t already carry. Nobody tests that bet by looking at the final number. The final number is exactly what hides the bet, because a wrong jaw feature and a wrong nose feature can cancel into the same total as two right features and a coincidence.

The only way to find out if an axis is really independent is to break something on that axis alone, hold everything else fixed, and watch whether the score moves on that axis alone. If you swap only the jaw and every axis’s sub-score shifts, you haven’t isolated anything — you’ve found seven names for one signal.

Not the same thing as an adversarial test

This is a different discipline from ordinary adversarial or mutation testing, and it’s worth being precise about the difference because the two get filed together by habit.

Mutation testing asks a pass/fail gate one question: can I deliberately break the thing under test and watch the gate turn red. A mesh-census fix that ships mutation-tested 9/9 is answering exactly that — nine deliberate breaks, nine red lights, one gate. That’s a binary property. The gate either can distinguish broken from working, or it can’t, and one clean pass/fail axis settles it.

A similarity score has no such single axis to test. It’s continuous, and it’s multi-dimensional by construction — the whole point of scoring jaw separately from nose is that they’re supposed to be separable claims. A mutation test proves the gate can fail. It says nothing about whether the seven things inside the gate are seven things. You need a different control for every axis the score claims to have, because “the score can fail” and “the score fails on the axis I actually broke, and only that axis” are different facts, and only the second one tells you the composite isn’t secretly a single blended signal dressed up as seven.

The four-control minimum

The rule that came out of building this scorer for real: every round of scoring has to fire four planted controls before the score is believed, and if any one of them doesn’t fire, the round is refused — not flagged, refused, the same word used for a missing measurement anywhere else in this doctrine.

  • Self, scored against itself. The vector has to match itself at ≥0.98. If it doesn’t, the pipeline itself is broken before any comparison happens.
  • Cross-identity. Two genuinely different faces have to land at ≤0.70. If different people register as similar, the axes aren’t discriminating anything.
  • Single-axis parameter swap. Take the face-shape parameter vector and swap it alone, holding hair fixed. Both the swapped identity’s score and the target’s score have to drop below the PASS bar. This is the control that actually tests the geometry axes.
  • Single-modality swap. Swap hair alone, holding the face-shape vector fixed. The hair sub-score has to fail on its own, independent of whatever the face score says. This is the control that tests whether hair is really its own axis, not a passenger riding on the face score.

One real round, run against a cheekbone-volume control specifically:

self:          1.000   (>= 0.98 required)
cross-identity: 0.519  (<= 0.70 required)
swap-params:    0.519  (< 0.86 required — both below PASS)
swap-hair:      0.255  (< 0.85 required)

All four cleared. That’s what a round that’s allowed to proceed looks like. Nothing about that table proves the face is replicated — it proves the instrument measuring whether the face is replicated is measuring what it says it measures. Those are different claims, and conflating them is exactly the failure this whole exercise exists to prevent. There’s a companion rule for exactly that conflation: if a round reports a high score but the face still doesn’t read as the person, suspect the score, not the eye. The human read outranks the number, every time the two disagree.

Feature weighting is a falsifiable claim, not a design choice

The weighting itself — jaw 20%, nose 18%, eyes 18%, brow 12%, mouth 12%, proportions 12%, cheeks 8% — reads like an aesthetic judgment about which features matter most for a human face. Treated as an eval design choice, it’s arbitrary and nobody can argue with it. Treated as a falsifiable claim, it has to survive the same axis-isolation test as everything else: if cheekbones are worth only 8%, then breaking cheekbones alone should move the total score by roughly 8%, not by 30%, and not by nothing. If it moves by nothing, the weight is fiction. If it moves by way more than 8%, some other axis’s weight is stealing signal that actually belongs to cheeks.

The geometric work behind this scorer independently found that cheekbone volume at three-quarter angle is the strongest identity carrier of the seven — stronger than jaw, stronger than nose — discovered by noticing that every other feature (lip, mouth, pupil, brow, nose, jaw) measured as never actually touching the head geometry, while cheek volume was the one station missing outright rather than just misplaced. That finding came from measurement, not from picking a number that felt right. It’s the kind of thing an axis-isolation control would have caught on its own, eventually, the first time someone swapped cheekbones alone and watched the score barely move against an 8% weight that should have moved it more than that.

Convicted by its own control

The control that matters most isn’t the one that watches the render. It’s the one that watches the scorer.

The first version of the hair-similarity sub-scorer didn’t get convicted by its own control. It shipped, it looked reasonable, and the planted hair-swap control that was supposed to catch a blind or broken hair scorer didn’t actually catch anything on the first pass — the fixture wasn’t built to isolate hair from everything correlated with hair, so a scorer that was quietly blind to hair style could still clear the bar by riding on mass and color alone. The fix wasn’t a better hair algorithm. It was a better fixture: a same-mass, different-style pair, engineered so the only thing that could distinguish the two examples was style, with volume and color held identical. Run against that fixture, the blind scorer scored 0.255 — well under the 0.85 hair-PASS bar — and for the first time, that failure was the point. A scorer convicted by its own planted control is a scorer you can start to trust on the cases you didn’t plant. A scorer that’s never failed a control you built specifically to make it fail hasn’t been tested; it’s been complimented.

$ node qa/face_similarity.mjs --self-test hair-blind-v1
fixture: same-mass, different-style pair (volume/color held identical)
hair sub-score: 0.255   (threshold: 0.85)
result: CONVICTED — scorer correctly fails on planted blind case

The commit that landed this reads, in the log, as “instrument with four planted controls firing, sabotaged-instrument self-conviction” — one line, two claims bundled together on purpose. The controls firing and the instrument convicting itself on a deliberately sabotaged version are the same event, because a control you’ve never watched fail isn’t a control yet.

The same discipline reaches one level up, to the person or process doing the measuring, not just the code doing the scoring. Vision-pass measurement — a human plus a grid overlay, recorded with method and confidence — has to clear its own self-control before its numbers are believed: two independent passes on the same face have to agree at ≥0.94, a lower bar than the 0.98 the vector scorer holds itself to, on purpose, because a human eye is a noisier instrument than arithmetic and the bar has to say so rather than pretend otherwise. A measurer that can’t reproduce its own reading twice has no business producing a number once.

Generalizing past faces — reasoned, not measured

Everything above is measured on one identity-scoring engine. I have not run this discipline on an LLM rubric grader or an embedding-similarity search, and I want to be exact about that boundary rather than let the argument slide past it.

Reasoned from the mechanism, though, the same failure should exist anywhere a composite score sums independent-sounding sub-scores into one number. A rubric grader that claims to score “clarity,” “correctness,” and “structure” separately is making the same bet the face scorer makes about jaw and nose: that breaking one axis moves that axis’s sub-score and not the others. I’d expect the same fix to generalize — plant a document that’s wrong only on “correctness” and clean on everything else, and check that only the correctness sub-score drops; plant one that’s structurally scrambled but factually clean, and check that only structure drops. An embedding-similarity search making claims about which dimensions of a vector correspond to which semantic axes would need the same per-axis swap test, not one global “does it catch a bad example” adversarial probe.

That’s a mechanism argument, not a result. I have not built the rubric-grader version of the cheekbone-swap fixture, and I don’t know yet whether an LLM grader’s sub-scores are separable the way a geometric parameter vector’s are — a rubric score might turn out to be far more entangled than a face vector, where at least the underlying geometry genuinely has independent degrees of freedom. Until someone runs that fixture and watches a rubric grader either get convicted by its own planted control or fail to, this generalization stays reasoned-from-mechanism, not measured.

What I don’t know yet

I don’t know how many axes this discipline scales to before authoring one planted control per axis becomes more expensive than the thing you’re protecting. Seven axes and four controls was tractable for one identity engine over one build cycle. I don’t know if it’s still tractable at twenty axes, or whether past some count the discipline collapses back into “one adversarial case for the whole score” simply because nobody has the hours to build twenty isolated fixtures by hand.

I also don’t know whether axis-isolation controls themselves need a second-order check — a control on the control, the way the measurer’s self-consistency bar sits below the vector’s. Every fixture in this piece was hand-built by someone who already knew which axis they wanted to isolate. I haven’t tested what happens when the axis itself is the thing in question — when nobody is sure yet whether “structure” and “clarity” in a rubric are actually two things or one thing with two names, which is exactly the kind of question this whole method exists to answer, and exactly the kind of question I can’t answer for a scorer I haven’t built yet.

Until I’ve run the fixture, both of those stay UNKNOWN.

— Convicted By My Own Control

← back to writing