In a model category, I have tools to show that mapping spaces are *contractible*. But if I want to show a mapping space is *empty or contractible*, is there anything I can do on general grounds?


The idea is this. Suppose I have a type of structure I'm interested in, and a collection of objects. To each object I assign a space parameterizing the choices required to equip that object with the structure in question. If all these parameter spaces are *empty-or-contractible*, that means the structure is "property-like": an object either has the structure or it doesn't; it can't carry different versions of the same structure. If the parameter spaces are all *contractible*, this means that in fact every object carries a unique version of the structure. Let me illustrate with an example of each.


**A contractible space of choices: property-like structures that always exist.** For example, in Joyal's model structure for quasicategories, suppose I want to show that the space of composites of two composable morphisms in a quasicategory $X$ is always contractible. This reduces to showing that the horn inclusion $\Lambda^1[2] \to \Delta[2]$ is an acyclic cofibration (since this implies that the fibers of $X^{\Delta[2]} \to X^{\Lambda^1[2]}$ are contractible).


Of course, this is immediate from typical descriptions of the model structure, but more generally I should consider myself lucky if all I have to do to answer a question is show that one explicit map is an acyclic cofibration, since I can work with explicit generators to make this a matter of combinatorics. (There's an asterisk in this case because in this model structure really I only know how to understand anodyne extensions combinatorially and not acyclic cofibrations in general, but in practice this understanding usually suffices.)


**An empty-or-contractible space of choices: property-like structures that don't always exist.** But now, again working in the Joyal model structure, suppose I want to show that the space of retracts of a given idempotent in a quasicategory is always either empty or contractible. This doesn't reduce to showing that the inclusion of the free idempotent into the free retract is an acyclic cofibration, because that would be too strong -- it would imply that every idempotent has a retract, which is not the case.


The closest thing I can think of is to perform a Bousfield localization to force every idempotent to have a retract, and then show that this map is an acyclic cofibration in the new model structure. But this only shows that if a quasicategory has *all* split idempotents (and I have to check that these are exactly the fibrant objects in the localized model structure), then the space of retracts for a given idempotent is contractible -- it doesn't tell me anything about quasicategories where some but not all idempotents split.


In this particular case, Lurie shows this fact using the theory of cofinality. But this is something specific to the example, not a general approach to the understanding property-like structures, even if we restrict our attention to quasicategories.


**Question:** Do model categories afford some general method for understanding property-like structures on their objects/morphisms, analogous to the method of showing that certain maps are acyclic cofibrations? Or can these things only be understood on a case-by-case basis?



Property-like structure in a model category
Let us say that a map $f : X \to Y$ in an $\infty$-category is an *embedding* if, for every object $Z$, the map of spaces $\mathrm{Hom}(Z,X) \to \mathrm{Hom}(Z,Y)$ is an embedding (that is, has either empty or contractible fibers). It is easy to define this notion on the level of model categories. A map $f : X \to Y$ in a model category is an *embedding* if, for every (cofibrant) object $Z$, the map of homotopy function complexes $\mathrm{hMap}(Z,X) \to \mathrm{hMap}(Z,Y)$ is an embedding.


I believe this is all that can be said in a general model category about this notion. The reason is that embeddings in $\infty$-categories can behave very adly (just as monomorphisms in ordinary categories), so there is no reason to believe that there should be some nice general theory that allows to work with them in arbitrary model category.


If we have some specific model category in mind, then we can try to choose some nice presentation of homotopy function complexes to prove that some specific map is an embedding. For example, in the case of the Joyal model structure, there are at least two such choices. Both of them were discussed here: [Homotopy function complex for quasi-categories](https://mathoverflow.net/questions/248662/homotopy-function-complex-for-quasi-categories).


Now, let's say we have a map of quasicategories $i : A \to B$ and we want to show that, for every quasicategory $X$, the map $X^B \to X^A$ is an embedding ($i$ is the inclusion of the free idempotent into the free retract in your example). This is equivalent to asking the map $\mathrm{hMap}(B,X) \to \mathrm{hMap}(A,X)$ to be an embedding. If we choose the first presentation of $\mathrm{hMap}$ in the question cited above, then this map is an embedding if and only if $X$ has the right lifting property with respect to the pushout-product of $i$ with maps $\partial \Delta'[n] \to \Delta'[n]$, $n > 0$ (we need to assume that $i$ is a cofibration for this). Here, $\Delta'[n]$ is the nerve of the groupoid $\{ 0 \simeq \ldots \simeq n \}$.


This is similar to the situation with the map $\Lambda^1[2] \to \Delta[2]$ that you mentioned, but the problem is that objects $\Delta'[n]$ are more complicated than the objects $\Delta[n]$ that we have in the latter, so it is quite hard to prove this directly. If we define $\mathrm{hMap}(X,Y)$ as the largest Kan complex contained in $Y^X$, then the combinatorics of the involved simplicial sets becomes more manageable, but even then I don't see how to prove this directly.


