Reference. Fundamental Components of Deep Learning: A category-theoretic approach

Deep learning, despite its remarkable achievements, is still a young field. Like the early stages of many scientific disciplines, it is marked by the discovery of new phenomena, ad-hoc design decisions, and the lack of a uniform and compositional mathematical foundation. From the intricacies of the implementation of backpropagation, through a growing zoo of neural network architectures, to the new and poorly understood phenomena such as double descent, scaling laws or in-context learning, there are few unifying principles in deep learning. This thesis develops a novel mathematical foundation for deep learning based on the language of category theory. We develop a new framework that is a) end-to-end, b) unform, and c) not merely descriptive, but prescriptive, meaning it is amenable to direct implementation in programming languages with sufficient features. We also systematise many existing approaches, placing many existing constructions and concepts from the literature under the same umbrella. In Part I we identify and model two main properties of deep learning systems parametricity and bidirectionality by we expand on the previously defined construction of actegories and Para to study the former, and define weighted optics to study the latter. Combining them yields parametric weighted optics, a categorical model of artificial neural networks, and more. Part II justifies the abstractions from Part I, applying them to model backpropagation, architectures, and supervised learning. We provide a lens-theoretic axiomatisation of differentiation, covering not just smooth spaces, but discrete settings of boolean circuits as well. We survey existing, and develop new categorical models of neural network architectures. We formalise the notion of optimisers and lastly, combine all the existing concepts together, providing a uniform and compositional framework for supervised learning.

Cite

Cite as @gavranovicFundamentalComponentsDeep (helia, typst) · \cite{gavranovicFundamentalComponentsDeep} (LaTeX)
BibTeX
bibtex · 9 lines
@phdthesis{gavranovicFundamentalComponentsDeep,
 title = {Fundamental {{Components}} of {{Deep Learning}}: {{A}} Category-Theoretic Approach},
 author = {Gavranović, Bruno},
 date = {2024},
 langid = {english},
 school = {University of Strathclyde},
 eprint = {2403.13001},
 archiveprefix = {arXiv}
}
hayagriva YAML (typst)
yaml · 10 lines
gavranovicFundamentalComponentsDeep:
  type: thesis
  title: 'Fundamental {Components} of {Deep Learning}: {A} Category-Theoretic Approach'
  author: Gavranović, Bruno
  date: 2024
  organization: University of Strathclyde
  serial-number:
    arxiv: '2403.13001'
  language: en-US
  genre: Doctoral dissertation
Cited by (1)

Reinforcement Learning in Categorical Cybernetics hedges-2025-reinforcement

DOI · arXiv
Cites 261 works (15 here)
With notes (15)

Profunctor Optics, a Categorical Update clarke-2024-profunctor

Optics are bidirectional data accessors that capture data transformation patterns such as accessing subfields or iterating over containers. Profunctor optics are a particular choice of representation supporting modularity, meaning that we can construct accessors for complex structures by combining simpler ones. Profunctor optics have previously been studied only in an unenriched and non-mixed setting, in which both directions of access are modelled in the same category. However, functional programming languages are arguably better described by enriched categories; and we have found that some structures in the literature are actually mixed optics, with access directions modelled in different categories. Our work generalizes a classic result by Pastro and Street on Tambara theory and uses it to describe mixed V-enriched profunctor optics and to endow them with V-category structure. We provide some original families of optics and derivations, including an elementary one for traversals. Finally, we discuss a Haskell implementation.
DOI · arXiv

Bayesian open games bolt-2023-bayesian

This paper generalises the treatment of compositional game theory as introduced by Ghani et al. in 2018, where games are modelled as morphisms of a symmetric monoidal category. From an economic modelling perspective, the notion of a game in the work by Ghani et al. is not expressive enough for many applications. This includes stochastic environments, stochastic choices by players, as well as incomplete information regarding the game being played. The current paper addresses these three issues all at once.
DOI · arXiv

Diegetic Representation of Feedback in Open Games capucci-2023-diegetic

DOI · arXiv

Value Iteration is Optic Composition hedges-2023-value

DOI · arXiv

Compositional thermostatics baez-2023-compositional

We define a thermostatic system to be a convex space of states together with a concave function sending each state to its entropy, which is an extended real number. This definition applies to classical thermodynamics, classical statistical mechanics, quantum statistical mechanics, and also generalized probabilistic theories of the sort studied in quantum foundations. It also allows us to treat a heat bath as a thermostatic system on an equal footing with any other. We construct an operad whose operations are convex relations from a product of convex spaces to a single convex space and prove that thermostatic systems are algebras of this operad. This gives a general, rigorous formalism for combining thermostatic systems, which captures the fact that such systems maximize entropy subject to whatever constraints are imposed upon them.
DOI · arXiv

The Compositional Structure of Bayesian Inference braithwaite-2023-the

Bayes’ rule tells us how to invert a causal process in order to update our beliefs in light of new evidence. If the process is believed to have a complex compositional structure, we may observe that the inversion of the whole can be computed piecewise in terms of the component processes. We study the structure of this compositional rule, noting that it relates to the lens pattern in functional programming. Working in a suitably general axiomatic presentation of a category of Markov kernels, we see how we can think of Bayesian inversion as a particular instance of a state-dependent morphism in a fibred category. We discuss the compositional nature of this, formulated as a functor on the underlying category and explore how this can used for a more type-driven approach to statistical inference.
DOI · arXiv

Towards Foundations of Categorical Cybernetics capucci-2022-towards

DOI · arXiv

Translating Extensive Form Games to Open Games with Agency capucci-2022-translating

DOI · arXiv

Lenses for Composable Servers videla-2022-lenses

We implement the semantics of server operations using parameterised lenses. They allow us to define endpoints and extend them using classical lens composition. The parameterised nature of lenses models state updates while the lens laws mimic properties expected from HTTP. This first approach to server development is extended to use dependent parameterised lenses. An upgrade necessary to model not only endpoints, but entire servers, unlocking the ability to compose them together.
DOI · arXiv

Fibre optics braithwaite-2021-fibre

Lenses, optics and dependent lenses (or equivalently morphisms of containers, or equivalently natural transformations of polynomial functors) are all widely used in applied category theory as models of bidirectional processes. From the definition of lenses over a finite product category, optics weaken the required structure to actions of monoidal categories, and dependent lenses make use of the additional property of finite completeness (or, in case of polynomials, even local cartesian closure). This has caused a split in the applied category theory literature between those using optics and those using dependent lenses. The goal of this paper is to unify optics with dependent lenses, by finding a definition of fibre optics admitting both as special cases.
arXiv

Syntax and Semantics of Quantitative Type Theory atkey-2018-syntax

DOI

Compositional Game Theory ghani-2018-compositional

DOI · arXiv

A convenient category for higher-order probability theory heunen-2017-a

DOI · arXiv

Profunctor Optics: Modular Data Accessors pickering-2017-profunctor

DOI

Kan Extensions for Program Optimisation Or: Art and Dan Explain an Old Trick hinze-2012-kan

DOI
External (246)
gavranovicFundamentalComponentsDeep reference entries/refs/gavranovicFundamentalComponentsDeep/gavranovicFundamentalComponentsDeep.hel