Schema Care

Confidence Score Calibration: When 95% Doesn't Mean 95%

By Schema CarePublished Updated

Confidence score calibration is how closely a system's scores match how often it is actually right. If an extraction tool is well calibrated, the fields it scores at 95% are correct about 95 times in 100. You test calibration by grouping fields from a labeled sample into score bands and comparing each band's score with its observed accuracy.

What confidence score calibration means

Confidence score calibration means the score can be read as a probability. A calibrated system that marks a field 0.80 is right about 80% of the time across all fields it marks 0.80. The gap between the claimed number and the observed accuracy is the calibration error, and it can run in either direction.

The scikit-learn guide to probability calibration gives the standard definition: a well calibrated classifier is one where, "among the samples to which it gave a predict_proba value close to, say, 0.8, approximately 80% actually belong to the positive class." For document extraction, swap "belong to the positive class" for "were extracted correctly".

Two words describe the gap:

  • Overconfident. The score is higher than the observed accuracy. In a made-up example, fields marked 95% turn out right only 89% of the time.
  • Underconfident. The score is lower than the observed accuracy. In another made-up example, fields marked 75% turn out right 82% of the time.

Calibration is a separate property from ranking. A system can rank fields well, so that higher scores really do have fewer errors, and still be badly calibrated, so that the numbers themselves are off. The paper On Calibration of Modern Neural Networks (Guo et al., ICML 2017) reports that modern neural networks, "unlike those from a decade ago, are poorly calibrated", which is why a raw score from a model should not be taken at face value.

How do you check whether confidence scores are calibrated?

You check whether confidence scores are calibrated by running a labeled sample through the system, grouping the fields into score bands, and comparing each band's average score with the share of its fields that were right. A band whose observed accuracy falls well short of its average score is overconfident.

The method, step by step:

  1. Start from a labeled sample. Every field needs a known correct value, typed and checked by people. How large that sample should be, and which payers and layouts it should include, is covered in what a ground truth test set for medical documents contains.
  2. Keep the sample independent. The scikit-learn guide warns that a calibrator fitted on a model's own training data will be biased, because "performance of the classifier on its training data would be better than for novel data."
  3. Bin the scores. Group fields by score range, for example 70 to 80, 80 to 90 and so on. The same guide describes reliability diagrams that bin predictions this way, plotting each bin's average predicted probability against the fraction that turned out correct.
  4. Compare each band. Subtract observed accuracy from the average score. A positive gap means overconfident; a negative gap means underconfident.
  5. Check the counts. A band with only 20 fields gives a noisy answer. Treat thin bands with caution.

An example reliability table

The table below uses illustrative numbers on an example test set of 5,100 fields. None of these figures describe a real system.

Score bandFieldsAverage score (predicted accuracy)Correct fieldsObserved accuracyVerdict
70% to 80%30075%23478%Slightly underconfident
80% to 90%50085%41583%Close
90% to 95%90092.5%79288%Overconfident
95% to 98%1,40096.5%1,27491%Overconfident
98% to 100%2,00099%1,97098.5%Close

The example has a clear story. The bottom and top bands behave. The middle-high bands, 90% to 98%, claim more than they deliver, and that is exactly where a 90% or 95% threshold would sit. A team using this system with a 90% threshold would accept fields from the overconfident bands and see more errors than the scores suggest.

When a high confidence field is wrong

A high confidence field is wrong when the system reads the page clearly but draws the wrong conclusion from it. The characters are crisp, so the reading scores well, yet the value lands in the wrong field, belongs to a different line, or is a printed value that differs from what the document means.

The errors that tend to arrive with confident scores in this kind of system:

  • Right text, wrong field. The billed amount and the allowed amount are both sharp numbers in neighboring columns. If the system picks the wrong column, the number is read perfectly and placed badly.
  • Right text, wrong line. On a multi-line EOB, a value from service line 3 can be attached to service line 4 when rows sit close together.
  • Clean print, unusual meaning. A payer prints "0.00" in a column that normally holds a payment, because the line was denied. The reading is correct; whether the field should be zero or empty depends on your rules.
  • Familiar-looking but new layouts. A layout close to one the system knows can be read confidently with the wrong mapping.

Confident errors are the hardest kind to catch, because no threshold will route them to a person. Two defenses help. Cross field checks that catch extraction errors, such as confirming that the amounts on each service line balance, catch values that are individually confident but together impossible. And sampling accepted fields for quality checks shows how often confident errors happen at all. Both are parts of the wider practice of human in the loop document processing, where people check what the system cannot judge for itself.

Recalibrating confidence scores per document type and field

Recalibrating confidence scores per document type and field means fitting a separate correction for each group whose scores drift differently. EOB amounts and intake form names come from different layouts, print quality and handwriting, so one correction for both will leave at least one of them off. Measure each group on its own reliability table first.

The Guo et al. paper describes temperature scaling, "a single-parameter variant of Platt Scaling", as "surprisingly effective at calibrating predictions" on most of the datasets it tested. In plain terms, a recalibration step takes the raw score and maps it to a new one so that the new numbers line up with observed accuracy on a labeled sample.

Why separate groups matter, with example reasoning:

  • EOB amounts are printed, usually crisp, and sit in tables. Their scores may be high and slightly overconfident because of column mix-ups.
  • Intake names are often handwritten. Their scores may be lower and spread out, with a different gap at each band.
  • A single correction fitted to the combined sample would split the difference, nudging amounts down a little and names up a little, and leave both partly wrong.

Recalibrating per group needs enough labeled fields in each group to fill the bands. If a group is too small to measure, keep it on a conservative threshold until you have more data.

Once you trust the numbers, choosing the line itself follows how to pick a starting extraction threshold from test data.

Is an overconfident extraction model worse than an underconfident one?

An overconfident extraction model is usually worse for billing data than an underconfident one. Overconfidence lets wrong values pass a threshold and post without review, so the cost lands later as payment errors and rework. Underconfidence sends correct values to review, which costs reviewer time but rarely puts a wrong number into an account.

The two mistakes cost different things:

OverconfidentUnderconfident
What happens at the thresholdWrong fields score above the line and passCorrect fields score below the line and wait
Who noticesOften a patient, a payer or a month-end reconciliationThe review team, right away
Typical costPosting corrections, balance disputes, reworkExtra review time
Visible in the queue?NoYes

The table explains why overconfidence is the more dangerous of the two: it is invisible inside the review process. An underconfident system announces itself with a long queue. An overconfident one looks efficient until errors surface downstream.

That said, heavy underconfidence has a real cost too. If reviewers spend most of their time approving values that were already right, they start approving without looking. A queue full of correct fields trains people to click through.

Payment posting is where these costs show up first. The EOBs and remittances category covers how EOB data moves into posting and reconciliation.

Calibration drift after a payer changes its form layout

Calibration drift is what happens when scores that matched observed accuracy stop matching it, usually because the documents changed. A payer that redesigns its EOB layout can leave scores looking just as high while the fields they describe are wrong more often. The fix is to re-measure calibration after any big change in incoming documents.

Research on model uncertainty supports caution here. The paper Can You Trust Your Model's Uncertainty? (Ovadia et al., NeurIPS 2019) evaluated uncertainty under dataset shift, meaning inputs that differ from the training data, and found that "traditional post-hoc calibration does indeed fall short" there. A correction fitted on last year's layouts is not guaranteed to hold on this year's.

Signs that drift has started:

  • Corrections in the review queue cluster on one payer or one field.
  • The share of fields under the threshold changes suddenly with no change in volume.
  • Spot checks of accepted fields find more errors than the reliability table predicted.

When you see any of these, pull a fresh labeled sample from the affected payer or document type, rebuild its reliability table, and adjust its threshold or correction. Keep the old table so you can compare.

Drift is also why field-level traceability matters. When every value links back to its place on the page, a reviewer checking a suspected drift problem can see at once whether the new layout moved a column. Schema Care returns each field with its score and that page link, across the document types Schema Care reads. How accuracy itself varies by page type and scan quality is covered in how accurate OCR is for medical records.

All posts in Human Review and Confidence