/-- The Yoneda embedding for preadditive categories sends an object `Y` to the presheaf sending an
object `X` to the group of morphisms `X ⟶ Y`. At each point, we get an additional `End Y`-module
structure, see `preadditiveYonedaObj`.
-/
@[simps]
def preadditiveYoneda : C ⥤ Cᵒᵖ ⥤ AddCommGroupCat.{v} where
  obj Y := preadditiveYonedaObj Y ⋙ forget₂ _ _
  map f :=
    { app := fun X =>
        { toFun := fun g => g ≫ f
          map_zero' := Limits.zero_comp
          map_add' := fun g g' => add_comp _ _ _ _ _ _ }
      naturality := fun X X' g => AddCommGroupCat.ext fun x => Category.assoc _ _ _ }
  map_id _ := by ext; dsimp; simp
  map_comp f g := by ext; 

Proof state:
case w.h.w
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
X✝ Y✝ Z✝ : C
f : X✝ ⟶ Y✝
g : Y✝ ⟶ Z✝
x✝¹ : Cᵒᵖ
x✝ :
  ↑(({ obj := fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat,
              map := fun {X Y} f =>
                NatTrans.mk fun X_1 =>
                  { toZeroHom := { toFun := fun g => g ≫ f, map_zero' := (_ : 0 ≫ f = 0) },
                    map_add' :=
                      (_ :
                        ∀
                          (g g' :
                            ↑(((fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat) X).obj
                                X_1)),
                          (g + g') ≫ f = g ≫ f + g' ≫ f) } }.obj
          X✝).obj
      x✝¹)
⊢ (({ obj := fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat,
                map := fun {X Y} f =>
                  NatTrans.mk fun X_1 =>
                    { toZeroHom := { toFun := fun g => g ≫ f, map_zero' := (_ : 0 ≫ f = 0) },
                      map_add' :=
                        (_ :
                          ∀
                            (g g' :
                              ↑(((fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat) X).obj
                                  X_1)),
                            (g + g') ≫ f = g ≫ f + g' ≫ f) } }.map
            (f ≫ g)).app
        x✝¹)
      x✝ =
    (({ obj := fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat,
                  map := fun {X Y} f =>
                    NatTrans.mk fun X_1 =>
                      { toZeroHom := { toFun := fun g => g ≫ f, map_zero' := (_ : 0 ≫ f = 0) },
                        map_add' :=
                          (_ :
                            ∀
                              (g g' :
                                ↑(((fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat)
                                        X).obj
                                    X_1)),
                              (g + g') ≫ f = g ≫ f + g' ≫ f) } }.map
              f ≫
            { obj := fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat,
                  map := fun {X Y} f =>
                    NatTrans.mk fun X_1 =>
                      { toZeroHom := { toFun := fun g => g ≫ f, map_zero' := (_ : 0 ≫ f = 0) },
                        map_add' :=
                          (_ :
                            ∀
                              (g g' :
                                ↑(((fun Y => preadditiveYonedaObj Y ⋙ forget₂ (ModuleCat (End Y)) AddCommGroupCat)
                                        X).obj
                                    X_1)),
                              (g + g') ≫ f = g ≫ f + g' ≫ f) } }.map
              g).app
        x✝¹)
      x✝

Next tactic:
dsimp