arXiv:2608.26465cs.CLAug 2026

Manuscript Offprint

arXiv:2608.26465

Compositional Generalization via Structural Identification in a Category-Theoretic Framework

Akihiro Maeda, Thomas Seiller, Yohei Oseki

Abstract

Compositional generalization is usually evaluated through model accuracy. We instead ask which structural or lexical identifications make held-out COGS examples admissible from the structures observed in training. Sentences are represented as functors from syntactic addresses to lexical tokens, and selective collapses induce Kan extensions that propagate observed associations. Across 21 COGS generalization types, admissibility follows distinct identification profiles, while residual failures separate unsupported structural templates. These data-side diagnoses characterize what the training corpus licenses under specified identifications, without training a predictive model.

1 Introduction

Large language models generalize broadly across language tasks, yet remain unreliable under systematic distribution shifts involving novel combinations of familiar components. Compositional generalization concerns this ability to interpret such novel combinations [Lake and Baroni, 2018]. COGS [Kim and Linzen, 2020] is a representative benchmark, including lexical items in novel grammatical roles, familiar structures in unseen combinations, and recursive structures beyond those observed during training.

Model accuracy shows whether a learner succeeds, but not which distinctions in the training data must be identified to generalize a held-out case. We apply category theory to formalize this process. Identifying selected structural or lexical distinctions induces a left Kan extension that propagates observed associations across the identified positions. We hypothesize that compositional-generalization phenomena differ in the identifications sufficient to make them compatible with the training data, and test this hypothesis on COGS.

We represent a sentence as a functor from a category of syntactic addresses to a word category. A syntactic collapse identifies addresses, while a lexical collapse identifies token classes. These collapses determine the Kan extensions tested below. The Boolean case treated here is the discrete instance of a more general enriched-nucleus construction related to singular-value decomposition [Bradley et al., 2024, Gastaldi et al., 2026b].

Our contribution is an operational characterization of COGS generalization. Each generalization type is associated with structural or lexical identifications, while unresolved cases reveal whether the obstruction is structural or lexical. This separates what the training data licenses from what a learner

Preprint.

Figure

Figure 1: A COGS sentence is represented as a functor Fx:Ax→WxF_x : \mathcal{A}_x \to \mathcal{W}_x. The prefix relation theme ⪯\preceqtheme.nmod_on is carried to the dependency cake →\rightarrowtable. A corpus is a family of such functors; for computation, we reduce it to a relation R⊆A×VR \subseteq \mathcal{A} \times V, where VV is the vocabulary. The syntactic collapse σ\sigma acts on the address side and the lexical collapse τ\tau on the lexical side.

actually realizes. The resulting operations provide candidate inductive biases for future language models, following the broader program of deriving learning principles from mathematical structure in compositional language models [Maeda et al., 2026].

References (18)