Ordinary homotopy is a way to probe objects in an (∞,1)-topos by mapping spheres into them:
the ordinary homotopy group of an object is the fiber over of the morphism
In this sense homotopy is the notion that is Eckmann-Hilton dual to cohomology.
For a detailed discussion see
This duality suggests that more generally we may be entitled to speak for and objects in of
as the homotopy of with co-coefficients in .
Examples of such constructions exist, but are rarely thought of (or even recognized as) generalizations of the notion of homotopy. Rather, by the above duality, the same situation is usually regarded in the context of cohomology, which, still by the above duality, is just as well.
abelian cosheaf homotopy
nonabelian homotopy
differential homotopy
twisted homotopy