Bayes-Consistent Losses for Adaptive Inference in Classification
Organizations: University of Oxford · McGill University
Abstract
Adaptive inference systems balance accuracy and inference cost by routing inputs to models with varying capabilities. Although jointly training models and routers is empirically more sample-efficient than training them separately, principled losses for joint training remain underexplored. We address this gap in a classification setting by proposing cost-sensitive hinge losses for jointly training classifiers with single-stage or cascade routers. Single-stage routers directly select a model per input, whereas cascade routers sequentially decide at each stage whether to predict with the current model or defer to the next stage, which uses a more accurate but more costly model. For both settings, we prove linear calibration bounds establishing Bayes consistency: minimizing the hinge risk recovers the Bayes-optimal risk under the target cost-sensitive zero-one loss. Moreover, since routers can require more labeled data to train than classifiers, we propose a novel post-training prediction-powered inference (PPI) procedure that uses unlabeled data to refine a trained single-stage router. Experiments on synthetic and real datasets demonstrate that the proposed hinge losses are effective for joint training and that PPI can correct routing errors when labeled data is scarce.
Figures & tables
Appendix figures & tables9 assets
Supplementary material from the paper’s appendix.
Appendix
| Method | Error Rate | Avg Cost | Test Empirical Risk |
| Hinge (ours) | 0.1626 | 0.0344 | 0.1970 |
| Joint CE | 0.1870 | 0.0334 | 0.2204 |
| FrugalGPT [ Chen et al., 2024a ] | 0.2195 | 0.0351 | 0.2546 |
| TREACLE [ Zhang et al., 2024 ] | 0.1951 | 0.0328 | 0.2279 |
Adaptive Model Routing
Adaptive model routing selects models or specialized experts per input to balance prediction quality, computational cost, latency, and resource constraints.
See all 92 papers