In Cat there is a factorization system $(E,M)$ where $E$ is the class of initial functors and $M$ is the class of discrete opfibrations; see
We can construct an analogous factorization system in any 1-exact and countably-coherent 2-category.
A morphism $f:A\to B$ in a 2-category $K$ is initial if it is left orthogonal to discrete opfibrations. That is, whenever $g:C\to D$ is a discrete opfibration, the following square is a pullback in $Cat$:
Every morphism in a 1-exact countably-coherent 2-category (in particular, in an $n$-pretopos for $n\ge 1$) factors, up to isomorphism, as an initial morphism followed by a discrete opfibration.
By the 2-categorical analogue of a standard theorem about factorization systems in 1-categories, it suffices to show that
The first point is true in any 2-category. For the second, we factor the inclusion as
and observe that both forgetful functors have left adjoints. The left adjoint to $DOpf(X) \to Opf(X)$ is discretization in the 1-exact and countably-coherent 2-category $Opf(X)$. The left adjoint to $Opf(X) \to K/X$ constructs the “free opfibration” on a functor $f:A\to X$, which is given by $A\times_X X^{\mathbf{2}}$.
In any 1-exact countably-coherent 2-category, (initial, discrete opfibration) is a (2-categorical) factorization system.
In any 1-exact countably-coherent 2-category, each pullback functor $f^*:DOpf(Y)\to DOpf(X)$ has a left adjoint $Lan_f$.
$Lan_f$ is given by composing with $f$, then factoring into an initial morphism followed by a discrete opfibration.
In a 1-category, every morphism is a discrete opfibration, so the only initial morphisms are isomorphisms. The factorization system (isomorphisms,all morphisms) is well-known.
In a (2,1)-category, the discrete opfibrations are precisely the faithful morphisms. Thus, in this case the comprehensive factorization system coincides with the (eso+full, faithful) factorization system.
The appropriate Beck-Chevalley condition for the adjunctions $Lan_f\dashv f^*$ refers not to pullback squares, but to comma squares. The easiest proof of this fact uses the internal logic. We start with an internal characterization of initial morphisms, analogous to the classical characterization in $Cat$ as the functors $f:A\to B$ for which each comma category $(f/b)$, for $b\in B$, is nonempty and connected.
For the rest of this page we make the standing assumption that $K$ is a 1-exact and countably-coherent 2-category.
A morphism $f:A\to B$ in $K$ is initial iff the following are internally valid:
where for each $i$, $\varphi_i$ expresses “there is a zigzag of length $i$ connecting $\alpha_1$ and $\alpha_2$ over $b$.”
Thus, for instance, we have
and so on.
$f:A\to B$ will be initial iff the discrete-opfibration part of its factorization is an equivalence. By construction, this factorization is the discrete reflection of $X = A\times_B B ^{\mathbf{2}} \to B$ in $Opf(B)$, which is constructed as the quotient of the equivalence relation $X_1$ generated by $X ^{\mathbf{2}}$ (the power taken in $Opf(B)$). Therefore, this discrete reflection will be the terminal object $1_B$ iff
It is fairly evident that $X\to B$ is eso iff the first displayed sequent holds in $K$. For the second, note that the kernel of $X\to B$ in $Opf(B)$ (or equivalently, in $K/B$) is just the pullback $X\times_B X$, since $B$ is discrete as an object of $K/B$. By definition of $X$, this pullback can be computed as the lax limit
and therefore it is precisely the context of the second displayed sequent. Since $X_1$ is the equivalence relation generated by $X ^{\mathbf{2}}$, it is necessarily contained in this kernel, so it suffices to show the converse implication. But $X_1$ is defined as the symmetric transitive closure of the image of $X ^{\mathbf{2}}$, which makes it essentially a countable union of “zigzags” from $X ^{\mathbf{2}}$, and this translates directly into the conclusion of the second sequent.
Initial morphisms in $K$ are stable under transfer across comma squares, in the sense that if
is a comma square with $f$ initial, then $q$ is also initial.
Given the characterization of initial morphisms in Lemma 1, we can simply observe that the usual proof of this fact in $Cat$ takes place entirely in countably-coherent logic.
The adjunctions $Lan_f\dashv f^*$ for discrete opfibrations in $K$ satisfy the Beck-Chevalley condition for comma squares. That is, if
is a comma square, then the canonical transformation $Lan_q p^* \to g^* Lan_f$ between functors $DOpf(A)\to DOpf(B)$ is an equivalence.
Note that unlike the case for a pullback square, there is no possible “handedness” ambiguity in saying that a comma square satisfies the Beck-Chevalley condition; there is no transformation $Lan_p q^* \to f^* Lan_g$ at all.
The existence of the transformation in the correct direction also depends on the fact that opfibrational slices are functorial at the level of 2-cells. In particular, for a comma square there is no transformation $\Sigma_q p^* \to g^*\Sigma_f$ between functors $K/A\to K/B$.
Given a discrete opfibration $X\to A$, let $X\to Lan_f X \to C$ be the (initial,discrete-opfibration) factorization of the composite $X\to A \overset{f}{\to} C$. Now by properties of comma squares and pullbacks, the pasting composite
is also a comma square, and thus so is
where the upper 2-cell is opcartesian for the opfibration $Lan_f X \to C$, and the map $p^* X \to g^* Lan_f X$ is obtained from the universal property of the pullback square on the bottom. Again, it follows from general properties of pullbacks and comma squares that the top square in this latter diagram is also a comma square. Thus, by Lemma 2, its left-hand morphism is initial. But then the left-hand composite $p^*X \to g^* Lan_f X \to B$ is an (initial, discrete-opfibration) factorization of $p^*X \to (f/g) \to B$, and hence it exhibits the desired equivalence $Lan_q p^*X \simeq g^* Lan_f X$.
Passing to 2-cell duals, we obtain:
For a comma square as above, the canonical transformation $Lan_p q^* \to f^* Lan_g$ between functors $DFib(B)\to DFib(A)$ is an equivalence.