{-# OPTIONS --without-K --safe #-}
open import Categories.Bicategory using (Bicategory)

module Categories.Bicategory.Object.Product {o ā„“ e t} (š’ž : Bicategory o ā„“ e t) where

open import Level

open Bicategory š’ž
open import Categories.Category using (_[_,_])
open import Categories.Morphism using (_ā‰…_)
open import Categories.Morphism.HeterogeneousEquality
open import Categories.Morphism.Notation using (_[_ā‰…_])

record Product  (A B : Obj) : Set (o āŠ” ā„“ āŠ” e āŠ” t) where
  infix 10 āŸØ_,_āŸ©ā‚ āŸØ_,_āŸ©ā‚‚
  field
    AƗB : Obj
    Ļ€a : AƗB ā‡’ā‚ A
    Ļ€b : AƗB ā‡’ā‚ B
    āŸØ_,_āŸ©ā‚ : āˆ€ {Ī“} ā†’ Ī“ ā‡’ā‚ A ā†’ Ī“ ā‡’ā‚ B ā†’ Ī“ ā‡’ā‚ AƗB
    āŸØ_,_āŸ©ā‚‚ : āˆ€ {Ī“}{fa ga : Ī“ ā‡’ā‚ A}{fb gb : Ī“ ā‡’ā‚ B}
           ā†’ fa ā‡’ā‚‚ ga ā†’ fb ā‡’ā‚‚ gb ā†’ āŸØ fa , fb āŸ©ā‚ ā‡’ā‚‚ āŸØ ga , gb āŸ©ā‚

    Ī²ā‚a : āˆ€ {Ī“} f g ā†’ hom Ī“ A [ Ļ€a āˆ˜ā‚ āŸØ f , g āŸ©ā‚  ā‰… f ]
    Ī²ā‚b : āˆ€ {Ī“} f g ā†’ hom Ī“ B [ Ļ€b āˆ˜ā‚ āŸØ f , g āŸ©ā‚  ā‰… g ]
    Ī²ā‚‚a : āˆ€ {Ī“}{fa ga fb gb}(Ī±a : hom Ī“ A [ fa , ga ])(Ī±b : hom Ī“ B [ fb , gb ])
        ā†’ Along Ī²ā‚a _ _ , Ī²ā‚a _ _ [ Ļ€a ā–· āŸØ Ī±a , Ī±b āŸ©ā‚‚ ā‰ˆ Ī±a ] 
    Ī²ā‚‚b : āˆ€ {Ī“}{fa ga fb gb}(Ī±a : hom Ī“ A [ fa , ga ])(Ī±b : hom Ī“ B [ fb , gb ])
        ā†’ Along Ī²ā‚b _ _ , Ī²ā‚b _ _ [ Ļ€b ā–· āŸØ Ī±a , Ī±b āŸ©ā‚‚ ā‰ˆ Ī±b ] 

    Ī·ā‚ : āˆ€ {Ī“} p ā†’ hom Ī“ AƗB [ p ā‰… āŸØ Ļ€a āˆ˜ā‚ p , Ļ€b āˆ˜ā‚ p āŸ©ā‚ ]
    Ī·ā‚‚ : āˆ€ {Ī“}{p p'}(Ļ• : hom Ī“ AƗB [ p , p' ])
       ā†’ Along (Ī·ā‚ _) , (Ī·ā‚ _) [ Ļ• ā‰ˆ āŸØ Ļ€a ā–· Ļ• , Ļ€b ā–· Ļ• āŸ©ā‚‚ ]