# Compositional Active Inference II: Polynomial Dynamics. Approximate Inference Doctrines

arXiv: https://arxiv.org/abs/2208.12173 · HTML: https://mlsanity.com/paper/2208.12173/

## Key facts

- Cited by 2 papers in the map (data through 14 Oct 2026).
- Builds on 14 of its 31 references that are in the map.
- First posted on arXiv 25 Aug 2022.

## Builds on (most cited first, 14 of 14)

- [The free energy principle for action and perception: A mathematical review](https://mlsanity.com/paper/1705.09156/) (2017)
- [A synthetic approach to Markov kernels, conditional independence and theorems on sufficient statistics](https://mlsanity.com/paper/1908.07021/) (2019)
- [Categorical Foundations of Gradient-Based Learning](https://mlsanity.com/paper/2103.01931/) (2021)
- [A free energy principle for a particular physics](https://mlsanity.com/paper/1906.10184/) (2019)
- [Disintegration and Bayesian Inversion via String Diagrams](https://mlsanity.com/paper/1709.00322/) (2017)
- [A Convenient Category for Higher-Order Probability Theory](https://mlsanity.com/paper/1701.02547/) (2017)
- [Profunctor Optics, a Categorical Update](https://mlsanity.com/paper/2001.07488/) (2020)
- [Categorical Stochastic Processes and Likelihood](https://mlsanity.com/paper/2005.04735/) (2020)
- [Learners' Languages](https://mlsanity.com/paper/2103.01189/) (2021)
- [Cyber Kittens, or Some First Steps Towards Categorical Cybernetics](https://mlsanity.com/paper/2101.10483/) (2021)
- [Directed Containers as Categories](https://mlsanity.com/paper/1604.01187/) (2016)
- [Open Dynamical Systems as Coalgebras for Polynomial Functors, with Application to Predictive Processing](https://mlsanity.com/paper/2206.03868/) (2022)
- [Diegetic Representation of Feedback in Open Games](https://mlsanity.com/paper/2206.12338/) (2022)
- [Dependent Optics](https://mlsanity.com/paper/2204.09547/) (2022)

## Built on by (most cited first, 2 of 2)

- [Towards Compositional Interpretability for XAI](https://mlsanity.com/paper/2406.17583/) (2024)
- [Active Inference in String Diagrams: A Categorical Account of Predictive Processing and Free Energy](https://mlsanity.com/paper/2308.00861/) (2023)

## Abstract (arXiv)

We develop the compositional theory of active inference by introducing activity, functorially relating statistical games to the dynamical systems which play them, using the new notion of approximate inference doctrine. In order to exhibit such functors, we first develop the necessary theory of dynamical systems, using a generalization of the language of polynomial functors to supply compositional interfaces of the required types: with the resulting polynomially indexed categories of coalgebras, we construct monoidal bicategories of differential and dynamical ``hierarchical inference systems'', in which approximate inference doctrines have semantics. We then describe ``externally parameterized'' statistical games, and use them to construct two approximate inference doctrines found in the computational neuroscience literature, which we call the `Laplace' and the `Hebb-Laplace' doctrines: the former produces dynamical systems which optimize the posteriors of Gaussian models; and the latter produces systems which additionally optimize the parameters (or `weights') which determine their predictions.
