# Poster 28863

- Kind: Poster
- Talk page and recording: https://iclr.cc/virtual/2025/poster/28863

> Transcript of the talk's recording (session_asr), made by speech recognition or taken from the host's captions. It may contain errors. The words are the speakers'; listen to the recording on the talk's page before quoting it.

So I'm here to present our open source Python package from normal computing called Posteriors and the accompanying paper that's been accepted at ICLR 2025. So Posteriors is a package for scalable Bayesian learning and it's fully open source. So go check out the repo at the normal computing GitHub, which I've got a link there.
Okay, so it's a PyTorch package for scalable Bayesian learning. What is Bayesian learning? It's about incorporating data into a model via a posterior distribution that represents uncertainty in our unknown parameters theta in comparison to maximum likelihood -based approaches that represent the unknown parameter by a single point estimate. So what are the benefits of Bayes in the scalable setting of modern language models and big data?
Well, in the paper we say there are three main benefits. Firstly, we have out-of-distribution performance. So by averaging over multiple plausible parameters that are consistent with the training data in the model as given by the posterior distribution, we get better out-of-distribution performance than if you just use a single-point estimate. So that's the first benefit on the left-hand side.
Then we have the setting of continual learning or online learning, which as we can see on the right hand side of the equation there is very natural. It's a very natural formulation in the Bayesian setting, but is quite tricky in the maximum likelihood setting because you get this forgetting if you continuously do gradient descent.
And then finally, we have the decomposition of predictive uncertainty that Bayesian gives you, gets you to split it between epistemic and aleatoric uncertainty, where epistemic is the sort of bad one, which is sort of your hallucination uncertainty, which deteriorates as you have more data. And then aleatoric uncertainty is just your natural uncertainty that is present in the model. So these are things such as synonyms and starts new sentences in the language model setting.
um okay so how does posteriors help with this and what are the contributions of the paper well the paper has three main contributions of course we start with introducing the uh
package, some of the design choices there. In particular, our second rate contribution is a unifying framework for stochastic gradient sense, so optimization algorithm, stochastic gradient MCMC. So this is an MCMC algorithm that uses stochastic gradients to sample from the posterior, but we have this temperature parameter that allows you to bring it back to the stochastic gradient descent format. So we have optimization and sampling all within the same framework. And then if we extend this to the parallel setting where we have many chains.
then you absorb deep ensemble and then a Bayesian version that's consistent for the true posterior as in it converges to true posterior in the infinite sample limit which is very nice and then finally we have our experiments which are large-scale including language models from the LAMA series in a Bayesian learning setting okay
So just briefly on Posteriors, it's designed based on PyTorch. It uses PyTorch as the backend, so it composes seamlessly with all of the greatest ecosystem that comes with PyTorch, including all of the machine learning models that you can find on the Transformers library.
is extensible so it's designed in a way that we can really easy add new methods and very general methods at that. It's functional so this is sort of JAX inspired using PyTorch's functional API so this means that it's much closer to the mathematics with the manipulations of gradients which is nicer for us. It's scalable so it's designed to be mini batch first so it's enforcing you to treat your data in batch format which is not normally the case for Bayesian software.
And finally, the transformations are designed so that all of the model specific arguments are preloaded at the start. So then you could swap between different Bayesian learning algorithms as easily as possible. So here's a little teaser on the experiments, but you should really go check those out in the paper. Each one is designed, there's three experiments, each one is designed to justify the benefits that I said at the start, the benefits of Bayesian learning.
Um, so yeah, please go check it out, read the paper, get involved on the GitHub. Thank you very much.
