l3lab/ntp-mathlib huggingface dataset:
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => 

Proof state:
case a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (𝟙 B.X ⊗ M.act) ≫ M.act
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (α_ A.X A.X M.X).hom
case a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| f.hom ⊗ 𝟙 (A.X ⊗ M.X)
case a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| 𝟙 B.X ⊗ f.hom ⊗ 𝟙 M.X

Next tactic:
rw [Mod_.assoc_flip]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
⊢ (A.mul ⊗ 𝟙 M.X) ≫ (f.hom ⊗ 𝟙 M.X) ≫ M.act =
    (α_ A.X A.X M.X).hom ≫
      (f.hom ⊗ 𝟙 (A.X ⊗ M.X)) ≫ (𝟙 B.X ⊗ f.hom ⊗ 𝟙 M.X) ≫ (α_ B.X B.X M.X).inv ≫ (B.mul ⊗ 𝟙 M.X) ≫ M.act

Next tactic:
slice_rhs 3 4 => rw [associator_inv_naturality]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => 

Proof state:
case a.a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (𝟙 B.X ⊗ f.hom ⊗ 𝟙 M.X) ≫ (α_ B.X B.X M.X).inv
case a.a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| B.mul ⊗ 𝟙 M.X
case a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| M.act
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (α_ A.X A.X M.X).hom
case a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| f.hom ⊗ 𝟙 (A.X ⊗ M.X)

Next tactic:
rw [associator_inv_naturality]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
⊢ (A.mul ⊗ 𝟙 M.X) ≫ (f.hom ⊗ 𝟙 M.X) ≫ M.act =
    (α_ A.X A.X M.X).hom ≫
      (f.hom ⊗ 𝟙 (A.X ⊗ M.X)) ≫ (((α_ B.X A.X M.X).inv ≫ ((𝟙 B.X ⊗ f.hom) ⊗ 𝟙 M.X)) ≫ (B.mul ⊗ 𝟙 M.X)) ≫ M.act

Next tactic:
slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => 

Proof state:
case a.a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (f.hom ⊗ 𝟙 (A.X ⊗ M.X)) ≫ (α_ B.X A.X M.X).inv
case a.a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (𝟙 B.X ⊗ f.hom) ⊗ 𝟙 M.X
case a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| B.mul ⊗ 𝟙 M.X
case a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| M.act
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (α_ A.X A.X M.X).hom

Next tactic:
rw [← tensor_id, associator_inv_naturality]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
⊢ (A.mul ⊗ 𝟙 M.X) ≫ (f.hom ⊗ 𝟙 M.X) ≫ M.act =
    (α_ A.X A.X M.X).hom ≫
      ((((α_ A.X A.X M.X).inv ≫ ((f.hom ⊗ 𝟙 A.X) ⊗ 𝟙 M.X)) ≫ ((𝟙 B.X ⊗ f.hom) ⊗ 𝟙 M.X)) ≫ (B.mul ⊗ 𝟙 M.X)) ≫ M.act

Next tactic:
slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => 

Proof state:
case a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (α_ A.X A.X M.X).hom ≫ (α_ A.X A.X M.X).inv ≫ ((f.hom ⊗ 𝟙 A.X) ⊗ 𝟙 M.X)
case a.a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| (𝟙 B.X ⊗ f.hom) ⊗ 𝟙 M.X
case a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| B.mul ⊗ 𝟙 M.X
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| M.act

Next tactic:
rw [Iso.hom_inv_id_assoc]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
⊢ (A.mul ⊗ 𝟙 M.X) ≫ (f.hom ⊗ 𝟙 M.X) ≫ M.act =
    ((((f.hom ⊗ 𝟙 A.X) ⊗ 𝟙 M.X) ≫ ((𝟙 B.X ⊗ f.hom) ⊗ 𝟙 M.X)) ≫ (B.mul ⊗ 𝟙 M.X)) ≫ M.act

Next tactic:
slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => 

Proof state:
case a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| ((f.hom ⊗ 𝟙 A.X) ⊗ 𝟙 M.X) ≫ ((𝟙 B.X ⊗ f.hom) ⊗ 𝟙 M.X)
case a.a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| B.mul ⊗ 𝟙 M.X
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| M.act

Next tactic:
rw [← comp_tensor_id, tensor_id_comp_id_tensor]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
⊢ (A.mul ⊗ 𝟙 M.X) ≫ (f.hom ⊗ 𝟙 M.X) ≫ M.act = (((f.hom ⊗ f.hom) ⊗ 𝟙 M.X) ≫ (B.mul ⊗ 𝟙 M.X)) ≫ M.act

Next tactic:
slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => 

Proof state:
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| ((f.hom ⊗ f.hom) ⊗ 𝟙 M.X) ≫ (B.mul ⊗ 𝟙 M.X)
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
| M.act

Next tactic:
rw [← comp_tensor_id, ← f.mul_hom]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M✝ : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
M : Mod_ B
⊢ (A.mul ⊗ 𝟙 M.X) ≫ (f.hom ⊗ 𝟙 M.X) ≫ M.act = (A.mul ≫ f.hom ⊗ 𝟙 M.X) ≫ M.act

Next tactic:
rw [comp_tensor_id, Category.assoc]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        rw [comp_tensor_id, Category.assoc] }
  map g :=
    { hom := g.hom
      act_hom := by
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
⊢ ((fun M => mk M.X ((f.hom ⊗ 𝟙 M.X) ≫ M.act)) X✝).act ≫ g.hom =
    (𝟙 A.X ⊗ g.hom) ≫ ((fun M => mk M.X ((f.hom ⊗ 𝟙 M.X) ≫ M.act)) Y✝).act

Next tactic:
dsimp
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        rw [comp_tensor_id, Category.assoc] }
  map g :=
    { hom := g.hom
      act_hom := by
        dsimp
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
⊢ ((f.hom ⊗ 𝟙 X✝.X) ≫ X✝.act) ≫ g.hom = (𝟙 A.X ⊗ g.hom) ≫ (f.hom ⊗ 𝟙 Y✝.X) ≫ Y✝.act

Next tactic:
slice_rhs 1 2 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        rw [comp_tensor_id, Category.assoc] }
  map g :=
    { hom := g.hom
      act_hom := by
        dsimp
        slice_rhs 1 2 => 

Proof state:
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
| (𝟙 A.X ⊗ g.hom) ≫ (f.hom ⊗ 𝟙 Y✝.X)
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
| Y✝.act

Next tactic:
rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        rw [comp_tensor_id, Category.assoc] }
  map g :=
    { hom := g.hom
      act_hom := by
        dsimp
        slice_rhs 1 2 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
⊢ ((f.hom ⊗ 𝟙 X✝.X) ≫ X✝.act) ≫ g.hom = ((f.hom ⊗ 𝟙 X✝.X) ≫ (𝟙 B.X ⊗ g.hom)) ≫ Y✝.act

Next tactic:
slice_rhs 2 3 => rw [← g.act_hom]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        rw [comp_tensor_id, Category.assoc] }
  map g :=
    { hom := g.hom
      act_hom := by
        dsimp
        slice_rhs 1 2 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        slice_rhs 2 3 => 

Proof state:
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
| (𝟙 B.X ⊗ g.hom) ≫ Y✝.act
case a
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
| f.hom ⊗ 𝟙 X✝.X

Next tactic:
rw [← g.act_hom]
/-- A morphism of monoid objects induces a "restriction" or "comap" functor
between the categories of module objects.
-/
@[simps]
def comap {A B : Mon_ C} (f : A ⟶ B) : Mod_ B ⥤ Mod_ A where
  obj M :=
    { X := M.X
      act := (f.hom ⊗ 𝟙 M.X) ≫ M.act
      one_act := by
        slice_lhs 1 2 => rw [← comp_tensor_id]
        rw [f.one_hom, one_act]
      assoc := by
        -- oh, for homotopy.io in a widget!
        slice_rhs 2 3 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        rw [id_tensor_comp]
        slice_rhs 4 5 => rw [Mod_.assoc_flip]
        slice_rhs 3 4 => rw [associator_inv_naturality]
        slice_rhs 2 3 => rw [← tensor_id, associator_inv_naturality]
        slice_rhs 1 3 => rw [Iso.hom_inv_id_assoc]
        slice_rhs 1 2 => rw [← comp_tensor_id, tensor_id_comp_id_tensor]
        slice_rhs 1 2 => rw [← comp_tensor_id, ← f.mul_hom]
        rw [comp_tensor_id, Category.assoc] }
  map g :=
    { hom := g.hom
      act_hom := by
        dsimp
        slice_rhs 1 2 => rw [id_tensor_comp_tensor_id, ← tensor_id_comp_id_tensor]
        slice_rhs 2 3 => rw [← g.act_hom]
        

Proof state:
C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
inst✝ : MonoidalCategory C
A✝ : Mon_ C
M : Mod_ A✝
A B : Mon_ C
f : A ⟶ B
X✝ Y✝ : Mod_ B
g : X✝ ⟶ Y✝
⊢ ((f.hom ⊗ 𝟙 X✝.X) ≫ X✝.act) ≫ g.hom = (f.hom ⊗ 𝟙 X✝.X) ≫ X✝.act ≫ g.hom

Next tactic:
rw [Category.assoc]
instance : SpectralMapClass (SpectralMap α β) α β
    where
  coe := SpectralMap.toFun
  coe_injective' f g h := by 

Proof state:
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
f g : SpectralMap α β
h : f.toFun = g.toFun
⊢ f = g

Next tactic:
cases f
instance : SpectralMapClass (SpectralMap α β) α β
    where
  coe := SpectralMap.toFun
  coe_injective' f g h := by cases f; 

Proof state:
case mk
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
δ : Type u_5
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
g : SpectralMap α β
toFun✝ : α → β
spectral'✝ : IsSpectralMap toFun✝
h : { toFun := toFun✝, spectral' := spectral'✝ }.toFun = g.toFun
⊢ { toFun := toFun✝, spectral' := spectral'✝ } = g

Next tactic:
cases g