Suppose $S$ is a simplicial set, $X$ is a space, and we are given a map
\[
f: \text{Sing}\,X\to S.
\]
When is is possible to produce a map $X\to |S|$?
We can take the realization of $f$, to get $|f|:|\text{Sing}\;X|\to |S|$, and then the question becomes: when does $|f|$ factor through the counit map $|\text{Sing}\;X|\to X$ (at least up to homotopy)?
It does if $X$ is a CW-complex, which is not the case for my example. What about if $S$ is a Kan complex? Does that help, or are the properties of $X$ really the key here?