theorem extracted_formal_statement_47.{w, v, u} {Z : Type w} {ι : Type v} {f : ι → Z → ℝ} {Ω : Type u}
  [inst : MeasurableSpace Ω] {X : Ω → Z} [inst_1 : Countable ι] (h𝓕 : ∀ (I : ι), Measurable (f I ∘ X)) {n : ℕ} {I : ι}
  {i : Fin n} (h_original_goal : Measurable fun ω => f I (X (ω i).1) - f I (X (ω i).2)) :
  Measurable fun a => f I (X (a i).2) := sorry

State before:
Z : Type w
ι : Type v
f : ι → Z → ℝ
Ω : Type u
inst✝¹ : MeasurableSpace Ω
X : Ω → Z
inst✝ : Countable ι
h𝓕 : ∀ (I : ι), Measurable (f I ∘ X)
n : ℕ
I : ι
i : Fin n
⊢ Measurable fun ω => f I (X (ω i).1) - f I (X (ω i).2)

Tactic: apply Measurable.sub

State after:
[case hf
 Z : Type w
 ι : Type v
 f : ι → Z → ℝ
 Ω : Type u
 inst✝¹ : MeasurableSpace Ω
 X : Ω → Z
 inst✝ : Countable ι
 h𝓕 : ∀ (I : ι), Measurable (f I ∘ X)
 n : ℕ
 I : ι
 i : Fin n
 ⊢ Measurable fun a => f I (X (a i).1),
 case hg
 Z : Type w
 ι : Type v
 f : ι → Z → ℝ
 Ω : Type u
 inst✝¹ : MeasurableSpace Ω
 X : Ω → Z
 inst✝ : Countable ι
 h𝓕 : ∀ (I : ι), Measurable (f I ∘ X)
 n : ℕ
 I : ι
 i : Fin n
 ⊢ Measurable fun a => f I (X (a i).2)]

Relevant lemmas:
Measurable.sub : ∀ {G : Type u_2} {α : Type u_3} [inst : MeasurableSpace G] [inst_2 : Sub G] {m : MeasurableSpace α}
  {f g : α → G} [inst_3 : MeasurableSub₂ G], Measurable f → Measurable g → Measurable fun a => f a - g a