Manuscript Offprint

arXiv:2610.39043

Modular Bayesian Foundation Models: Bayesian time series encoders for OOD detection, routing and forecasting

Mame Diarra Toure, Quang Hung Pham, Mohamed Ryad Zemouri, David Stephens, Luc Vouligny, Martin Gagnon

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Bayesian time series encoders for OOD detection, routing and forecasting

Mame Diarra Toure

Department of Mathematics and Statistics McGill University

mame.toure@mail.mcgill.ca

Quang Hung Pham

Hydro-Quebec

Pham.QuangHung2@hydroquebec.com

Mohamed Ryad Zemouri

Hydro-Quebec

Zemouri.MohamedRyad@hydroquebec.com

David Stephens

Department of Mathematics and Statistics McGill University

david.stephens@mcgill.ca

Luc Vouligny

Hydro-Quebec

luc.vouligny@hydroquebec.com

Martin Gagnon

Hydro-Quebec

gagnon.martin11@hydroquebec.com

Abstract

Industrial systems continuously generate time series that vary in sampling frequency, scale, dynamics, and operating regime. Consequently a single time-series foundation model may not be able to represent all regimes effectively and retraining a large model for every new dataset or regime shift is computationally expensive. Modular foundation models address this issue by reusing specialised encoders trained on diverse datasets and by allowing the expansion of capabilities through the addition of new experts. This approach requires compact experts to minimize storage cost and a proper selection mechanism of experts for unseen data. We propose a modular foundation model framework that combines end-to-end Bayesian encoder training with uncertainty based routing. Using Singular Bayesian Neural Networks (SBNNs), we build a collection of compact Bayesian encoders whose epistemic uncertainty guides label-free selection. At the selected ranks, our Bayesian collection uses 63.8% less storage than its deterministic counterpart. We evaluate this framework on time-series data through distribution shift, encoder selection, and probabilistic forecasting. Across seven incoming datasets, uncertainty-based routing is competitive with distance-based routing in terms of forecast MSE, while reducing average ECE from 0.086 to 0.072 and average NLL from 0.907 to 0.836. It also increases PICP90 from 82.28% to 89.03%. In a separate model-family comparison, we evaluate the SBNN pipeline against full-rank Bayes by Backprop, deep ensembles, and MC Dropout. The SBNN pipeline achieves an average MSE of 0.390, comparable with 0.396 for deep ensembles, 0.389 for MC dropout, and 0.443 for the full-rank Bayesian model. It uses 63.9% fewer parameters than MC dropout, 81.9% fewer than the full-rank model, and 92.8% fewer than the deep ensemble. We also find that uncertainty-based routing helps shortlist useful experts for the downstream task. However, the reconstruction ranking within this shortlist does not necessarily carry over to forecasting.

References (100)

Couldn't load all references. Reload the page to try again.