# IVE Document Routing: Add an Abstain Path Before Automating Decisions

> Design a document-routing trial for IVE-4B with confidence and margin checks, a human-review path, and a labeled evaluation set.

Canonical article: https://modelrovia.com/guides/ive-document-routing-abstention/
Author: Modelrovia Editorial
Published: 2026-11-26
Updated: 2026-11-26

## Key takeaway

Measure both accepted-decision accuracy and review volume before choosing a routing threshold.

**IVE-4B and Ivonnet-0.8B return probabilities over supplied choices for document decisions.** Illuin's November 23 release describes text and image inputs, an English-focused training distribution, and a 16,384-token input limit. For routing invoices or support documents, define an abstention path alongside the available labels before wiring those scores into an automated workflow. [Author release notes](https://huggingface.co/blog/QuentinJG/ive-release)

## Use confidence and ambiguity together

Suppose your labels are invoice, receipt and other. A high top score and a large gap to the second score can be useful routing signals. Neither establishes accuracy on your documents. Start with a labeled set that includes cropped pages, incomplete scans and documents outside all three categories.

This standalone Python example consumes authored probability dictionaries. Its thresholds are illustrative.

~~~python
import math

def route(scores, threshold=0.85, margin=0.20):
    if set(scores) != {"invoice", "receipt", "other"}:
        return "review"
    values = list(scores.values())
    if any(isinstance(v, bool) or not isinstance(v, (int, float))
           or not math.isfinite(v) or v < 0 or v > 1 for v in values):
        return "review"
    if not math.isclose(sum(values), 1.0, abs_tol=0.001):
        return "review"
    ranked = sorted(scores.items(), key=lambda item: item[1], reverse=True)
    label, first = ranked[0]
    second = ranked[1][1]
    if first < threshold or first - second < margin or label == "other":
        return "review"
    return label

cases = [
    {"invoice": .92, "receipt": .05, "other": .03},
    {"invoice": .49, "receipt": .48, "other": .03},
    {"invoice": .04, "receipt": .03, "other": .93},
    {"invoice": .99, "receipt": .99, "other": .03},
]
for scores in cases:
    print(route(scores))
~~~

The local run printed invoice, review, review and review. The last input fails the probability-sum check. Adapt response parsing to the actual field structure returned by the model package before using this function. Preserve the raw answer beside the parsed scores so a parser error is distinguishable from an uncertain classification.

## Choose thresholds on your own document distribution

Split examples into a development set for selecting thresholds and a separate test set. For every threshold pair, count automated decisions, accepted mistakes and documents sent to review. A system that routes two easy pages perfectly may still leave most of the workload to people.

For example, if 80 of 100 documents are accepted and 76 are correctly routed, accepted-decision accuracy is 95% and coverage is 80%. Record the four mistakes by document type. A threshold suitable for sorting a reading queue may be unsuitable for triggering a payment workflow.

Keep the input within the model's documented length limit and inspect any preprocessing that shortens pages. A missing answer may reflect content removed before inference. For scanned files, the [OCR preparation guide](/guides/paddleocr-document-ocr/) covers checking important names and numbers before trusting downstream records.

**Verification on November 26.** We ran the four routing fixtures and checked the coverage arithmetic locally. These are synthetic scores. We did not download IVE or measure its calibration, latency or document accuracy.

## Sources & references

- [Illuin authors: IVE release and probability outputs, November 23](https://huggingface.co/blog/QuentinJG/ive-release)

[Editorial standards](https://modelrovia.com/methodology/)
