User blog comment:BlauesWasser/Why Zero Shouldn't be considered a cardinal/@comment-30754445-20180501091716/@comment-27513631-20180509193623

Yeah, that works as a definition of the natural numbers, and it comes with a canonical arbitrary map \(\text{out}:\mathbb N \to V\). Although the definition of the naturals works, many definitions come with a mapping like that (to the set that was used to define them), and it makes little sense to me to have such a mapping, or if it needs to exist, for it to have any unnecessary or arbitrary structure. I suppose that's why I'd object to that definition in such a setting, although it's considerably less substantial.

Anyhow, in type theory the statement \(a=_Ab\) is a type, like \(A\times B\) or any other. It is consistent to add an axiom to type theory which is literally the universal closure of \(A \simeq B \to A=B\).

This is a consequence of the univalence axiom, which states that the set of equivalences (a weakened notion of isomorphism) between two types is itself equivalent to the set of equalities between the two types (\((A \equiv B) \equiv (A=B)\)).

The weaker version is consistent with all equalities themselves being equal. This, however, is not really desirable for types, because equalities can be useful. All types, by construction, come with a way to get rid of their terms, and the way to get rid of equalities is by substituting equals for equals (indiscernibility of identicals). Now, the group \(\mathbb Z\) is isomorphic to itself in two ways (do nothing, and negate each element), and eliminating the associated equality should actually use the isomorphism used to construct it, in principle (I believe this is realised in cubical type theory).