A claims extraction system returns $1,250 and highlights a box on page 2. The value is right. The box is around the amount claimed, not the amount approved. In this fictional example, the two numbers happen to match. A test that checks only the value passes. A reviewer following the citation learns the wrong thing about where the amount came from.
Test the value and its source separately. Then test whether the source actually supports the field you asked for. A correct answer attached to the wrong evidence is a distinct failure, even when it would not change the output in this example.
1. Label what the reviewer needs to see
Start with one field that drives a real decision, such as an approved amount, a policy effective date, or a lab result and its unit. Write down what qualifies as source evidence before looking at the model's predictions. For approved amount, the evidence could be a labeled decision-summary line. For a value inside a table, it might include a row label and column header as well as the cell itself. If both an original and an amended form exist, decide whether only the signed amendment counts, and under what conditions.
For each test instance, label the expected value, document and page, and the smallest set of regions that supports the meaning. Record alternative locations only if each independently supports the same field. A repeated amount in a cover letter may count if it is explicitly labeled and authoritative for the task; a coincidentally identical amount in another field should not. If evidence is split across regions, record which regions must be present together.
Separate the number printed on a page from its location in the file. A packet can start with a cover sheet, reuse page numbers across attachments, or number an appendix separately. A viewer needs the exact version of the artifact and the physical page index, not just the label printed in its footer.
2. Check the coordinate space before judging the model
An extraction service can return geometry in pixels, page-relative fractions, or a provider-specific form. Amazon Textract describes normalized boxes and polygons. Google Document AI describes pixel and normalized vertices and image normalization. A set of valid coordinates can still highlight the wrong place if the viewer interprets them against another page image.
Store the coordinate space, origin, page dimensions where relevant, and page rotation or transformation needed to map to the viewer. If your team deskews or crops a scan before extraction, preserve enough information to map the result back to the artifact the reviewer opens. In a top-left-origin normalized space, multiplying the horizontal fraction by display width and the vertical fraction by display height works only when the displayed and annotated pages have the same framing and orientation. If they do not, apply the documented transform instead of adding a visual offset until a single page looks right.
Run a simple rendering check before comparing models: place known marks near opposite corners and the center on a small sample, including a rotated or cropped page. Draw the stored regions through the actual review interface at two zoom levels. If the overlay shifts or points to the adjacent line, fix that path first. That is an integration failure, not evidence that the model read the wrong number.
3. Give value, location, and support separate scores
- Value correctness: Does the normalized answer match the reference under the field's rule? Define how to handle units, signs, formatting and rounding before scoring.
- Source location: Does the citation open the right artifact and page? Where the field requires a region, does the overlay cover the annotated evidence rather than a neighboring row, field or entire page?
- Evidence support: Could a reviewer reach that specific answer from the cited material? For a calculated result, each required input must be traceable, with the calculation identified as derived. For a mismatch finding, cite both sides.
Region overlap can make regression tests reproducible. Intersection over union divides the shared area of two regions by their combined area; pick a threshold suitable for the annotation granularity and calibrate it on labeled examples. A high overlap score does not prove a citation supports the answer, and a narrow box may correctly capture a value but omit the unit or heading needed to interpret it. If an automated check cannot establish support, sample those cases for human review. Keep page-only answers in their own bucket when the workflow needs field-level citations.
Suppose a fictional set contains 30 required field instances. Twenty-seven have the right value, 24 point to a valid region, and 22 have both the right value and supporting evidence. Report the individual checks and the joint pass count against the same stated denominator. Keep unsupported answers and correct values with bad citations separate. For fields that should stay blank, use a separate denominator and check whether the system returned a plausible answer from an unrelated region. The companion guide on leaving a field blank covers those cases.
4. Seed cases that defeat a value-only test
Build a small release set with an identical number under two labels, an amended page that replaces an earlier value, a multi-page table where the units or header appear elsewhere, and a scan with changed rotation or cropping. Add a page-numbering trap and one genuinely unsupported field. Use the same expectations across model or preprocessing changes, but annotate each rendered variant in its own coordinate space. In a benchmark with tuning and holdout samples, keep variants of one source together.
Decide the release rule with the person who owns the workflow. For example, the test might require zero wrong-record citations for routing-sensitive fields in the held-out set, and send any ambiguous or unsupported approved amount to review. A pass on a small set is evidence about those cases, not proof of production accuracy. Preserve the three scores and some representative failure examples so the next regression can distinguish reading problems from overlay or source-selection problems.
Start with a handful of ways citations can fail rather than five hundred clean files. Use fictional sample documents to set up the test without customer records, then evaluate approved source material inside your own data boundary where needed. The first success is a reviewer who can open the right page, see the right evidence, and explain why it supports the answer.



