module Cat.Functor.Hom.Displayed
  {o β„“ o' β„“'} {ℬ : Precategory o β„“} (β„° : Displayed ℬ o' β„“')
  where

Displayed Hom functorsπŸ”—

Let be a displayed category over For every in the base, we can obtain a bifunctor from to where denotes the fibre category of at The action of on is given by just as in the non-displayed case.

Hom-over : βˆ€ {x y} β†’ Hom x y β†’ Functor (Fibre β„° x ^op Γ—αΆœ Fibre β„° y) (Sets β„“')
Hom-over u .Fβ‚€ (a , b) = el (Hom[ u ] a b) (Hom[ u ]-set a b)
Hom-over u .F₁ (f , h) g = hom[ idl _ βˆ™ idr _ ] (h ∘' g ∘' f)
Hom-over u .F-id = funext Ξ» f β†’
  apr' {q = idl _} (idr' f) βˆ™ idl[]
Hom-over u .F-∘ (f , h) (f' , h') = funext Ξ» g β†’
  hom[] (hom[] (h ∘' h') ∘' g ∘' hom[] (f' ∘' f)) β‰‘βŸ¨ disp! β„° βŸ©β‰‘
  hom[] (h ∘' hom[] (h' ∘' g ∘' f') ∘' f) ∎

We can also define partially applied versions of this functor.

Hom-over-from : βˆ€ {x y} β†’ Hom x y β†’ Ob[ x ] β†’ Functor (Fibre β„° y) (Sets β„“')
Hom-over-from u x' .Fβ‚€ y' = el (Hom[ u ] x' y') (Hom[ u ]-set x' y')
Hom-over-from u x' .F₁ f g = hom[ idl u ] (f ∘' g)
Hom-over-from u x' .F-id = funext Ξ» f β†’ idl[]
Hom-over-from u x' .F-∘ f g  = funext Ξ» h β†’
  smashl _ _ βˆ™ sym assoc[] βˆ™ sym (smashr _ _)

Hom-over-into : βˆ€ {x y} β†’ Hom x y β†’ Ob[ y ] β†’ Functor (Fibre β„° x ^op) (Sets β„“')
Hom-over-into u y' .Fβ‚€ x' = el (Hom[ u ] x' y') (Hom[ u ]-set x' y')
Hom-over-into u y' .F₁ f g = hom[ idr u ] (g ∘' f)
Hom-over-into u y' .F-id = funext Ξ» f β†’ idr[]
Hom-over-into u y' .F-∘ f g = funext Ξ» h β†’
  smashr _ _ βˆ™ assoc[] βˆ™ (sym $ smashl _ _ )