Skip to main content
QUICK REVIEW

[Paper Review] Partiality, Revisited: The Partiality Monad as a Quotient Inductive-Inductive Type

Thorsten Altenkirch, Nils Anders Danielsson|arXiv (Cornell University)|Oct 28, 2016
Logic, programming, and type systems17 references20 citations
TL;DR

This paper introduces a partiality monad based on a quotient inductive-inductive type (QIIT) that models partial computations without relying on countable choice, resolving a key limitation of Capretta's delay monad. By directly incorporating weak bisimilarity as equality via higher inductive-inductive construction, the authors achieve a constructive, quotient-based partiality monad that is equivalent to the quotiented delay monad under countable choice.

ABSTRACT

Capretta's delay monad can be used to model partial computations, but it has the "wrong" notion of built-in equality, strong bisimilarity. An alternative is to quotient the delay monad by the "right" notion of equality, weak bisimilarity. However, recent work by Chapman et al. suggests that it is impossible to define a monad structure on the resulting construction in common forms of type theory without assuming (instances of) the axiom of countable choice. Using an idea from homotopy type theory - a higher inductive-inductive type - we construct a partiality monad without relying on countable choice. We prove that, in the presence of countable choice, our partiality monad is equivalent to the delay monad quotiented by weak bisimilarity. Furthermore we outline several applications.

Motivation & Objective

  • To construct a partiality monad that correctly models weak bisimilarity as equality without assuming countable choice.
  • To overcome the limitations of setoid-based quotienting and 'setoid hell' in type theory.
  • To provide a constructive alternative to the quotiented delay monad, which otherwise requires countable choice to form a monad.
  • To enable reasoning about non-terminating programs in dependent type theory with proper equality and information hiding.
  • To lay the foundation for constructive domain theory and operational semantics in type theory.

Proposed method

  • Construct a higher inductive-inductive type (HIIT) that simultaneously defines the partiality monad and its equality relation (weak bisimilarity).
  • Use quotient inductive-inductive type (QIIT) structure to internalize weak bisimilarity as definitional equality in the monad.
  • Define the monad using coinductive constructors: 'now' for immediate results and 'later' for delayed computation.
  • Ensure that all operations respect weak bisimilarity by construction, avoiding the need for explicit proof obligations.
  • Leverage homotopy type theory techniques to embed quotienting directly into the type definition, avoiding reliance on external quotienting mechanisms.
  • Prove that the resulting monad is equivalent to the quotiented delay monad when countable choice is assumed.

Experimental results

Research questions

  • RQ1Can a partiality monad be constructed in type theory that correctly identifies weakly bisimilar computations without assuming countable choice?
  • RQ2Is it possible to define a monad structure on the quotient of the delay monad by weak bisimilarity without countable choice?
  • RQ3Can quotient inductive-inductive types be used to internalize equality and avoid setoid hell in constructive type theory?
  • RQ4How does the proposed monad compare to the standard delay monad and its quotiented variant in terms of equality and computational behavior?
  • RQ5What are the implications of this construction for constructive domain theory and operational semantics in dependent type theory?

Key findings

  • The proposed partiality monad is constructed as a quotient inductive-inductive type, avoiding the need for countable choice.
  • The monad is equivalent to the quotiented delay monad when countable choice is assumed, validating its correctness.
  • The construction naturally supports weak bisimilarity as equality, resolving the intensionality problem of the original delay monad.
  • The approach avoids 'setoid hell' by embedding equality into the type structure, enabling information hiding and modular reasoning.
  • The monad supports the definition of continuous functions such as 'isPositive' on quotiented reals, which are otherwise uncomputable in standard constructive settings.
  • The method enables the construction of definitional interpreters, type soundness proofs, and compiler correctness results in a constructive setting.

Better researchstarts right now

From paper design to paper writing, dramatically reduce your research time.

No credit card · Free plan available

This review was created by AI and reviewed by human editors.