Compositionality is at the heart of computer science and several other areas of applied category theory such as computational linguistics, categorical quantum mechanics, interpretable AI, dynamical systems, compositional game theory, and Petri nets. However, the meaning of the term seems to vary across the many different applications. This work contributes to understanding, and in particular qualifying, different kinds of compositionality. Formally, we introduce invariants of categories that we call zeroth and first homotopy posets, generalising in a precise sense the $\pi_0$ and $\pi_1$ of a groupoid. These posets can be used to obtain a qualitative description of how far an object is from being terminal and a morphism is from being iso. In the context of applied category theory, this formal machinery gives us a way to qualitatively describe the "failures of compositionality", seen as failures of certain (op)lax functors to be strong, by classifying obstructions to the (op)laxators being isomorphisms. Failure of compositionality, for example for the interpretation of a categorical syntax in a semantic universe, can both be a bad thing and a good thing, which we illustrate by respective examples in graph theory and quantum theory.
翻译:组合性是计算机科学以及应用范畴论其他若干领域(如计算语言学、范畴量子力学、可解释人工智能、动力系统、组合博弈论和Petri网)的核心概念。然而,该术语的含义在不同应用中似乎有所差异。本研究旨在理解并特别区分不同类型的组合性。形式上,我们引入称为零阶与一阶同伦偏序集的范畴不变量,这些不变量在精确意义上推广了群胚的 $\pi_0$ 和 $\pi_1$。这些偏序集可用于定性描述对象离终端对象有多远,以及态射离同构态射有多远。在应用范畴论的语境下,这一形式化机制通过分类(余)松弛函子成为强函子的阻碍,即分类(余)松弛子成为同构的阻碍,使我们能够定性描述"组合性的失效"——即特定(余)松弛函子未能保持强函子性质的现象。组合性的失效(例如在语义宇宙中对范畴句法的解释中)既可能是不利的也可能是有利的,我们分别通过图论和量子理论中的实例加以说明。