Theorem 5: minimizers of recover the latents on a convex body up to an invertible affine map
ProvedContrastiveInverts.delta_contrastive_identifies_affineLet be a convex body in , , and . Let be a metric induced by a norm, or a semi-metric of such a metric as in Lemma 1. Let the marginal be uniform and the conditional be as in eq. (5), . Let the mixing function be differentiable and injective on with .
Let be a class of encoders with measurable on . Assume the form of matches : some has on . If is differentiable on and minimises over , then is invertible and affine: there is an invertible affine map of with
So the latent sources are recovered up to an affine transformation.
Formalization Note "Invertible" is stated as invertibility of the affine map on . The paper's is encoded by encoders with values in .
import Mathlib import Definitions.Def_ContrastiveInverts_Basic open MeasureTheory Filter Topology
namespace ContrastiveInverts
theorem delta_contrastive_identifies_affine {N K : ℕ} (hNK : N ≤ K) (Z : Set (Vec N))
(hZ : IsConvexBody Z) (τ : ℝ) (hτ : 0 < τ)
(δ : Vec N → Vec N → ℝ) (hδ : IsNormSemimetric δ)
(X : Set (Vec K)) (g : Vec N → Vec K) (hgX : ∀ z ∈ Z, g z ∈ X) (hg_inj : Set.InjOn g Z)
(hg_diff : DifferentiableOn ℝ g Z)
(F : Set (Vec K → Vec N))
(hF : ∀ f' ∈ F, (∀ x ∈ X, f' x ∈ Z) ∧ AEMeasurable (f' ∘ g) (volume.restrict Z))
(hflex : ∃ f₀ ∈ F, ∀ z ∈ Z, ∀ z' ∈ Z,
bodyModelCond τ δ Z (f₀ ∘ g) z z' = expCond 1 δ Z z z')
(f : Vec K → Vec N) (hfF : f ∈ F) (hf_diff : DifferentiableOn ℝ f X)
(hmin : ∀ f' ∈ F,
deltaInfoNCELimit 1 δ τ δ Z (f ∘ g) ≤ deltaInfoNCELimit 1 δ τ δ Z (f' ∘ g)) :
∃ A : Vec N ≃ᵃ[ℝ] Vec N, ∀ z ∈ Z, f (g z) = A z := by sorry
end ContrastiveInvertsRead-back
What the Lean code literally says, in plain math · claude-opus-5-5
Setting. Fix natural numbers ( is not excluded). Write and for the Euclidean spaces with the standard inner product, and for Lebesgue measure on . The data of the statement are the following.
- Latent space. is a convex body: convex, compact, and with nonempty interior.
- Temperature. is a real number with .
- Similarity. is a norm-induced semimetric. There exist and such that for all , where:
- is a norm (not necessarily Euclidean): , , and ;
- restricts to a bijection of onto itself, is continuous on , and satisfies . Its values off are unconstrained.
- In particular, and .
- Generator. is a set and is a map such that:
- for every ;
- is injective on ;
- is differentiable on , in the sense of differentiability within at each point of .
- is not required to equal .
- Model class. is a set of maps . Every maps into , and is almost-everywhere measurable with respect to Lebesgue measure restricted to .
- Learned encoder. is an element of that is differentiable on .
Auxiliary objects. Write for the uniform probability measure on . For and , define the following.
- The ground-truth conditional, with rate :
- The model conditional:
All integrals are Bochner integrals. A non-integrable integrand gives the value , and division by gives .
Next, define the positive-pair law. is the measure on with density with respect to .
For , the contrastive loss is
Here and are independent and uniform on . This integral is again if the integrand is not integrable.
The limiting objective is
with the convention . If this limit does not exist, is an unspecified real number.
Hypotheses on the model class and on .
- (Realizability.) There exists such that, for all ,
as an equality of real numbers. The same appears in both conditionals; the model side carries and the ground-truth side carries .
- (Minimality.) For every ,
Conclusion. There exists an invertible affine map , that is, with an invertible linear map and , such that
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.