Selective classification for LLM routing with a manual review limit
Sources checked 3 min read · By the Eval Suites editors
In brief
Selective classification sends uncertain predictions to a fallback. Choose a confidence threshold by measuring two quantities on labeled cases: the share you can handle automatically and the error rate within that share. The threshold has to meet both your error limit and your manual review capacity.[1][2]
Measure selective risk among the cases the model accepts
Give each case a predicted class, a decision score, and a verified reference class. At a given threshold, coverage is the fraction of all cases whose scores qualify for automatic routing. With an equal cost for every wrong route, selective risk is the fraction of accepted cases routed incorrectly. A threshold that accepts zero cases has 0% coverage and undefined selective risk.[1][2]
Use the score to order cases. A value of 0.80 only means roughly 80% of similarly scored cases are correct if you have evidence the scores are calibrated for that outcome and workload. Estimate calibration separately on labeled data. You can still count observed errors at a threshold when the score has no probability interpretation.[3]
Choose a threshold that fits the queue
In an illustrative Cedar Museum inbox, a model assigns messages to ticketing, group visits or accessibility support. Approved cases route immediately and the rest go to staff. For this 20-message tuning sample, staff can review up to eight messages. The product owner allows at most 10% routing errors among automatically handled cases.
| Accept score at or above | Automatic routes | Wrong automatic routes | Coverage | Selective risk | Manual reviews |
|---|---|---|---|---|---|
| 0.85 | 6 | 0 | 30% | 0 of 6 (0%) | 14 |
| 0.75 | 12 | 1 | 60% | 1 of 12 (8.3%) | 8 |
| 0.60 | 16 | 2 | 80% | 2 of 16 (12.5%) | 4 |
| 0.50 | 19 | 3 | 95% | 3 of 19 (15.8%) | 1 |
Of the four cutoffs, 0.75 meets both limits on this sample. Lowering the cutoff to 0.60 saves four reviews and adds one wrong automatic route, enough to breach the error limit. The 0.85 row avoids errors on six messages and exceeds the team’s review capacity by six.
# (decision score, did the proposed route match the reference?)
cases = [
(.96, True), (.93, True), (.91, True), (.89, True), (.87, True),
(.85, True), (.84, True), (.82, True), (.80, True), (.79, False),
(.77, True), (.75, True), (.74, True), (.71, False), (.66, True),
(.60, True), (.58, True), (.52, False), (.50, True), (.42, False),
]
for threshold in [.85, .75, .60, .50]:
accepted = [correct for score, correct in cases if score >= threshold]
wrong = accepted.count(False)
print(f"{threshold:.2f}", len(accepted), wrong, len(cases) - len(accepted))Validate the cutoff on fresh messages before routing traffic
- Freeze the threshold and run it on a separate labeled set. Report accepted, wrongly routed and reviewed counts for the full set and each route that matters. Decide in advance which minimum evidence and route-specific limits the release needs.
- Convert the review share into staffing demand over a time window. At 100 incoming messages per staffed hour, a 40% review share implies 40 messages an hour at that mix. Check peak arrivals and review time before accepting the cutoff.
- If no cutoff meets both constraints, improve the decision score or route selected case types directly to review. Recheck error and queue size together after the policy or traffic changes.
A held-out batch can reveal a weak route hidden in the aggregate. If a wrong accessibility route has a greater consequence than a wrong ticketing route, give it an explicit limit and report its denominator. Zero observed errors among six accepted cases provides little evidence about that route’s true error rate. Plan the held-out sample around the failures you need to detect.
When you know how many routes failed, check where those messages went. Use a confusion matrix to trace routing errors to the wrong queue.
Related suites
Related reading
Sources
- 1. On the Foundations of Noise-free Selective Classification · El-Yaniv and Wiener · Paper · Sources checked
- 2. SelectiveNet: A Deep Neural Network with an Integrated Reject Option · Geifman and El-Yaniv · Paper · Sources checked
- 3. Probability calibration in scikit-learn · scikit-learn · Official docs · Sources checked