Directed type theory, with a twist

📅 2026-02-19
📈 Citations: 0
✨ Influential: 0
📄 PDF
🤖 AI Summary
This work proposes Twisted Type Theory (TTT) to overcome the limitations of existing type theories, which are largely confined to groupoid semantics and thus ill-suited for intrinsically reasoning about directed structures in categories. TTT introduces a “twisting” operation that transforms types depending simultaneously on covariant and contravariant variables into purely covariant forms. The semantics of TTT is grounded in a newly introduced notion of dependent two-sided fibrations (D2SFibs). By establishing a straightening–unstraightening theorem, the theory provides a novel semantic justification for the elimination rule of Hom types, thereby enabling a proof style analogous to that of Homotopy Type Theory (HoTT). As a demonstration of its expressiveness and practical utility in categorical reasoning, the paper presents a purely syntactic proof of the Yoneda lemma within TTT.

Technology Category

Knowledge Representation and Reasoning: Automated Reasoning and Theorem ProvingConstraint Satisfaction and Optimization: Satisfiability Modulo TheoriesGame Theory and Economic Paradigms: Cooperative Game Theory

Application Category

Semantics and Knowledge: Methods, algorithms and applications for the development of semantic models, knowledge graphs and other forms of structured data models with machine-interpretable semanticsGraph Algorithms and Modeling for the Web: Foundation models and LLMs for Web-related graphsSecurity and Privacy: Data transparency and provenance
📝 Abstract
In recent years, Homotopy Type Theory (HoTT) has had great success both as a foundation of mathematics and as internal language to reason about $\infty$-groupoids (a.k.a. spaces). However, in many areas of mathematics and computer science, it is often the case that it is categories, not groupoids, which are the more important structures to consider. For this reason, multiple directed type theories have been proposed, i.e., theories whose semantics are based on categories. In this paper, we present a new such type theory, Twisted Type Theory (TTT). It features a novel ``twisting'' operation on types: given a type that depends both contravariantly and covariantly on some variables, its twist is a new type that depends only covariantly on the same variables. To provide the semantics of this operation, we introduce the notion of dependent 2-sided fibrations (D2SFibs), which generalize Street's notion of 2-sided fibrations. We develop the basic theory of D2SFibs, as well as characterize them through a straightening-unstraightening theorem. With these results in hand, we introduce a new elimination rule for Hom-types. We argue that our syntax and semantics satisfy key features that allow reasoning in a HoTT-like style, which allows us to mimic the proof techniques of that setting. We end the paper by exemplifying this, and use TTT to reason about categories, giving a syntactic proof of Yoneda's lemma.
Problem

Research questions and friction points this paper is trying to address.

Directed type theory
Categories
Homotopy Type Theory
Dependent types
Yoneda lemma
Innovation

Methods, ideas, or system contributions that make the work stand out.

Twisted Type Theory
dependent 2-sided fibrations
straightening-unstraightening
directed type theory
Yoneda lemma
🔎 Similar Papers
No similar papers found.