Definition 2.2.1.1 (Bénabou). A $2$-category $\operatorname{\mathcal{C}}$ consists of the following data:
A collection $\operatorname{Ob}(\operatorname{\mathcal{C}})$, whose elements we refer to as objects of $\operatorname{\mathcal{C}}$. We will often abuse notation by writing $X \in \operatorname{\mathcal{C}}$ to indicate that $X$ is an element of $\operatorname{Ob}(\operatorname{\mathcal{C}})$.
For every pair of objects $X, Y \in \operatorname{Ob}(\operatorname{\mathcal{C}})$, a category $\underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}( X, Y)$. We refer to objects $f$ of the category $\underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y)$ as $1$-morphisms from $X$ to $Y$ and write $f: X \rightarrow Y$ to indicate that $f$ is a $1$-morphism from $X$ to $Y$. Given a pair of $1$-morphisms $f,g \in \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y)$, we refer to morphisms from $f$ to $g$ in the category $\underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y)$ as $2$-morphisms from $f$ to $g$. We will sometimes write $\gamma : f \Rightarrow g$ or $f \xRightarrow {\gamma } g$ to indicate that $\gamma $ is a $2$-morphism from $f$ to $g$.
For every triple of objects $X,Y,Z \in \operatorname{Ob}(\operatorname{\mathcal{C}})$, a composition functor
\[ \circ : \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}( Y, Z) \times \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y) \rightarrow \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Z). \]For every object $X \in \operatorname{Ob}(\operatorname{\mathcal{C}})$, a $1$-morphism $\operatorname{id}_{X} \in \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,X)$, which we call the identity $1$-morphism from $X$ to itself.
For every object $X \in \operatorname{Ob}(\operatorname{\mathcal{C}})$, an isomorphism $\upsilon _{X}: \operatorname{id}_{X} \circ \operatorname{id}_{X} \xRightarrow {\sim } \operatorname{id}_{X}$ in the category $\underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,X)$. We refer to the $2$-morphisms $\{ \upsilon _{X} \} _{X \in \operatorname{Ob}(\operatorname{\mathcal{C}}) }$ as the unit constraints of $\operatorname{\mathcal{C}}$.
For every quadruple of objects $W, X, Y, Z \in \operatorname{\mathcal{C}}$, a natural isomorphism $\alpha $ from the functor
\[ \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(Y, Z) \times \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}( X, Y) \times \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(W,X) \rightarrow \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(W, Z) \quad \quad (h,g,f) \mapsto h \circ (g \circ f) \]to the functor
\[ \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(Y, Z) \times \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}( X, Y) \times \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(W,X) \rightarrow \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(W, Z) \quad \quad (h,g,f) \mapsto (h \circ g) \circ f. \]We denote the value of $\alpha $ on a triple $(h,g,f)$ by $\alpha _{h,g,f}: h \circ (g \circ f) \xRightarrow {\sim } (h \circ g) \circ f$. We refer to these isomorphisms as the associativity constraints of $\operatorname{\mathcal{C}}$.
These data are required to satisfy the following pair of conditions:
- $(C)$
For every pair of objects $X,Y \in \operatorname{Ob}(\operatorname{\mathcal{C}})$, the functors
\[ \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y) \rightarrow \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y) \quad \quad f \mapsto f \circ \operatorname{id}_{X} \]\[ \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y) \rightarrow \underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}(X,Y) \quad \quad f \mapsto \operatorname{id}_{Y} \circ f \]are fully faithful.
- $(P)$
For every quadruple of composable $1$-morphisms
\[ V \xrightarrow {e} W \xrightarrow {f} X \xrightarrow {g} Y \xrightarrow {h} Z \]in $\operatorname{\mathcal{C}}$, the diagram of isomorphisms
\[ \xymatrix@C =-10pt@R=30pt{ & h \circ ((g \circ f) \circ e) \ar@ {=>}[rr]^{ \alpha _{h, g \circ f, e} }_{\sim } & & (h \circ (g \circ f)) \circ e \ar@ {=>}[dr]^{ \alpha _{h, g, f} \circ \operatorname{id}_ e}_{\sim } & \\ h \circ (g \circ (f \circ e) ) \ar@ {=>}[ur]^{ \operatorname{id}_ h \circ \alpha _{g,f,e} }_{\sim } \ar@ {=>}[drr]_{ \alpha _{h,g,f\circ e}}^{\sim } & & & & ((h \circ g) \circ f) \circ e \\ & & (h \circ g) \circ (f \circ e) \ar@ {=>}[urr]_{\alpha _{ h \circ g, f, e} }^{\sim } & & } \]commutes in the category $\underline{\operatorname{Hom}}_{\operatorname{\mathcal{C}}}( V, Z)$.