CLINC150
100%All test traffic was handled locally. At alpha .95, calibration agreement was .952, while test agreement was .930. The paper flags that gap.
Tracer Research / Open-source paper 02
Many AI systems pay a large model to choose from the same fixed set of labels on every request. TRACER learns from those past decisions. A fast local model handles the cases it can match reliably. Uncertain inputs still go to the LLM.
Every LLM classification call creates a labeled example: the input and the model's answer. TRACER turns those traces into a growing training set for a lightweight surrogate. An acceptor estimates when the surrogate will agree with the teacher LLM, and a held-out parity gate decides whether the resulting policy is allowed to handle traffic. The paper measures how much work can move local at four agreement targets. Banking77 reaches 83.2% test coverage with .959 teacher agreement at the strictest target. CLINC150 reaches full coverage, though its test agreement falls below that target. MNLI stays at zero because the representation cannot support reliable routing. The refusal is part of the result.
Figures above are from arXiv v1. The current open-source package has continued to evolve, and its later benchmarks should be read under their own setup.
In brief
Each production request leaves an input and the fixed label returned by the teacher LLM.
TRACER trains several small classifiers to reproduce those labels from text embeddings.
An acceptor decides which predictions can stay local and which requests should return to the LLM.
Choose the teacher-agreement bar. TRACER searches for the policy that handles the largest share of traffic while clearing that bar on held-out data.
The paper reports empirical agreement on fixed benchmarks. Live distributions can shift, so production monitoring remains necessary.01 / Classification
Intent detection, moderation, ticket routing, document tagging, and lead qualification all ask the same kind of question: which label from a known set fits this input?
A large language model can perform these jobs with little setup. It reads the input, follows a label schema in the prompt, and returns one answer. That convenience makes LLM classification common even when most requests follow familiar patterns.
As traffic accumulates, the system begins paying the same model to resolve many variations of decisions it has already made. The production log now contains supervision. Each pair of input and output says how the teacher handled one point in the workload.
"I returned an item but don't see it on my account?"
02 / Traces
TRACER collects these pairs and embeds each input into a numeric representation. It trains a pool of traditional classifiers, including logistic regression, linear SGD models, small multilayer perceptrons, and optional tree models. The candidate with the strongest teacher-label macro-F1 moves forward.
The target is teacher behavior. If the teacher assigns a wrong label or invents a label outside the requested schema, the trace records that answer. This distinction matters: a surrogate can agree closely with its teacher while both remain wrong against ground truth.
"I returned an item but don't see it on my account?"
refund_not_showing_up"What is the procedure for activating this card?"
activate_my_card"Are there ATM fees?"
atm_support03 / Learning to defer
Learning to defer, or L2D, adds a routing decision to classification. Each input can be answered by the surrogate or handed back to the teacher LLM.
The surrogate produces a probability for every label. A separate logistic-regression acceptor reads four signals from that distribution: the highest probability, the second-highest probability, the margin between them, and normalized entropy. Together, those signals estimate whether the surrogate will agree with the teacher on this input.
The acceptor score is compared with a threshold called tau. A score above tau returns the local label. A score below tau invokes the teacher. Held-out data determines the threshold.
A new classification request arrives.
The text becomes a fixed numeric representation.
A small classifier proposes a label and probabilities.
A learned score estimates teacher agreement.
The request avoids an LLM call.
The LLM answers and creates a new trace.
Cov = Pr[a(x) ≥ τ]TA = Pr[f(x) = T(x) | a(x) ≥ τ] ≥ αT(x)The teacher LLM's label for input x.
f(x)The lightweight surrogate's label.
a(x)The estimated chance that surrogate and teacher agree.
τThe routing threshold selected from held-out scores.
αThe operator's target teacher agreement.
CovThe share of inputs handled by the surrogate.
04 / The parity gate
The paper sweeps alpha across four targets. The policy with the highest coverage can serve only after it clears the target on a held-out shadow split and exceeds a 5% coverage floor.
Two policy families compete at every refit. A Global policy lets one surrogate handle all traffic when its overall agreement is high enough. An L2D policy keeps the acceptor and serves only the subset above tau. If every candidate fails, the teacher continues to receive every request.
The control below uses the four Banking77 test points reported in arXiv v1. Alpha is the calibration target. The agreement shown is the observed test result, which can land above or below that target.
At target alpha .95, the L2D policy handled 83.2% of test inputs and deferred 16.8% to the teacher.
05 / Results
Full local handling, selective deferral, and refusal all appear in the experiments. The last outcome establishes a useful boundary: some tasks need a richer representation before local routing is safe.
All test traffic was handled locally. At alpha .95, calibration agreement was .952, while test agreement was .930. The paper flags that gap.
At alpha .95, the L2D policy handled most test traffic locally and reached .959 teacher agreement on the handled slice.
No candidate cleared the gate across nine configurations. Frozen sentence-pair embeddings could not separate entailment, neutrality, and contradiction reliably.
| Task | Target α | Coverage | Teacher agreement | Ground-truth accuracy |
|---|---|---|---|---|
| Banking77 | .80 | 100% | .894 | .804 |
| Banking77 | .85 | 100% | .894 | .804 |
| Banking77 | .90 | 96.1% | .912 | .804 |
| Banking77 | .95 | 83.2% | .959 | .816 |
| CLINC150 | .80 to .95 | 100% | .930 | .924 |
| MNLI | .85 to .95 | 0% | Not applicable | Not applicable |
Under the token prices and prompt lengths used in the paper, 10,000 Banking77 calls per day cost about $9,500 per year. The 83.2% coverage result reduces that illustrative teacher cost by about $7,900 per year.
06 / The flywheel
Every request sent back to the teacher produces another labeled trace. Later refits gain evidence about cases the surrogate found difficult.
The paper divides training traces into five daily batches. Day 1 begins with 2,001 Banking77 traces. Each update merges the new batch and refits the policy from scratch. Coverage ends higher than it began, though it does not rise smoothly.
The dip on Day 3 and the smaller decline on Day 5 are important. A new batch can contain harder traffic, and recalibration can move the threshold. The gate protects the agreement target while the amount of traffic handled locally changes.
07 / Interpretability
TRACER produces artifacts about the partition between locally handled and deferred traffic. Operators can see which labels are stable, which inputs remain ambiguous, and how that boundary moves after a refit.
Contrastive boundary pairs give the quickest intuition. The two inputs below share the same teacher label in Banking77. The first is served by the surrogate at a high acceptor score. The second returns to the teacher.
"I returned an item but don't see it on my account?"
Teacher label: refund_not_showing_up
"Why hasn't my return cleared my account?"
Teacher label: refund_not_showing_up
Handled rate and teacher agreement for each class or length range.
Typical inputs from the handled and deferred groups within each label.
Similar teacher-labeled inputs that receive opposite routing decisions.
Per-label changes in handled rate after each refit.
Held-out cases where surrogate and teacher produce different labels.
The paper inspects these artifacts qualitatively. Their usefulness to practitioners has not yet been measured in a user study.
08 / Since the paper
The arXiv paper records the v1 experiment. Later repository releases strengthened the gate and added tools for checking a workload before training.
The current package uses a Clopper-Pearson lower bound plus a selection and verification split.
Inputs far from the training distribution return to the teacher even when classifier confidence is high.
tracer scan gives a conservative first look at whether the workload contains locally routable regions.
pip install tracer-llm
tracer demo
tracer fit traces.jsonl --target 0.95
tracer serve .tracer --port 8000
09 / Limits
The strongest reading of the paper is practical and specific: intent-classification traces can support large local offload under some representations, and the gate can reject a task that fails. Broader claims need broader experiments.
The surrogate copies teacher behavior, including errors and labels that fall outside the requested schema. It does not establish better ground-truth accuracy.
CLINC150 passed alpha .95 on calibration at .952 and reached .930 on test. Empirical gating did not fully transfer to unseen data.
The positive results cover two intent datasets with separable embedding clusters. MNLI failed on compositional reasoning.
All paper experiments use BGE-large-en-v1.5 embeddings. Different encoders may change the coverage and quality frontier.
The comparison uses a confidence-threshold logistic regression with full hindsight. Stronger learned routers and distillation methods remain future comparisons.
Artifacts received qualitative inspection, refits start from scratch, and live distribution shift still requires monitoring.
The paper contains the method, benchmark protocol, full alpha sweep, flywheel analysis, interpretability artifacts, limitations, and references. The MIT-licensed repository contains the working package.
@article{rida2026tracer,
title = {TRACER: Trace-Based Adaptive Cost-Efficient Routing for LLM Classification},
author = {Rida, Adam},
journal = {arXiv preprint arXiv:2604.14531},
year = {2026}
}
Version 1, Computer Science: Artificial Intelligence.
Read on arXiv Download PDF View GitHub