Share your thoughts, 1 month free Claude Pro on usSee more
WorkDL logo mark

Multi-Task Bayesian In-Context Learning

About

Bayesian predictive inference provides a principled framework for uncertainty quantification, data efficiency, and robust generalization. However, exact inference is often intractable, and scalable approximations may remain computationally expensive or require restrictive modeling assumptions that degrade predictive performance. Prior-Data Fitted and in-context models have recently emerged as an amortized alternative by learning to map datasets directly to predictive distributions, but existing approaches are tightly coupled to the support of the training prior and lack explicit mechanisms for adapting to new priors at test time, resulting in limited robustness under distribution shift. We introduce a multi-task in-context learning framework for amortized hierarchical Bayesian predictive inference that explicitly represents prior information as a prefix of in-context datasets. A transformer trained on sequences of prior and target tasks learns to adapt its predictions across families of priors. On a suite of evaluations with increasing difficulty, including out-of-meta-distribution priors and priors with high-dimensional latent structures, our method matches oracle Bayesian predictors while being orders of magnitude faster. We further demonstrate its practical relevance on a real-world spatiotemporal temperature prediction benchmark. Code is available at https://github.com/martianmartina/multi-task-bayesian-icl/.

Qingyang Zhu, Eric Karl Oermann, Kyunghyun Cho• 2026

Related benchmarks

TaskDatasetResultRank
Spatiotemporal temperature predictionERA5 IID 2019 (val)
NLL-2.29
4
Spatiotemporal temperature predictionERA5 IID 2019 (test)
NLL-2.33
4
Spatiotemporal temperature predictionERA5 2020 (test)
NLL-2.31
4
Spatiotemporal temperature predictionERA5 OOD 2019 (val)
NLL-2.06
4
Spatiotemporal temperature predictionERA5 OOD 2019 (test)
NLL-0.58
4
Posterior Predictive InferenceSpiral-flow prior (OoMD, mu=12)
KL Divergence to Oracle0.262
4
Showing 6 of 6 rows

Other info

Follow for update