Introduction
Discrete diffusion models learn distributions on categorical data by reversing a Markov noising process [1 , 11 ] . In language modeling, they provide an alternative to autoregressive sequence generation [15 ] . We study their finite-sample estimation error in Kullback–Leibler (KL) divergence under two standard noising mechanisms: uniform corruption , which replaces tokens with uniformly sampled tokens, and masked corruption , which replaces them with an absorbing mask token. Our objective is to determine whether these mechanisms attain the optimal estimation rates when the data distribution has an unknown sparse support.
For continuous diffusion models, Oko et al. [13 ] establish nearly minimax-optimal distribution estimation rates under smoothness assumptions. Related results show how score estimation and distribution recovery can exploit low-dimensional subspaces [4 ] and manifold structure [2 ] . As a discrete counterpart, we consider here support sparsity as structural assumption. For sequences of length d d d over a vocabulary of size K K K , the clean state space X 0 \mathcal{X}_0 X 0 has M : = K d M := K^d M := K d elements. An l l l -sparse distribution assigns positive probability to at most l l l sequences. We impose no geometric condition on these sequences, no independence assumption on their coordinates, and no lower bound on their positive probabilities. The relevant question is therefore whether diffusion-based estimation can adapt to l l l , rather than incur a statistical cost proportional to M M M .
Our starting point is to regularize the empirical score-entropy objective by its counterpart for uniformly distributed clean data. The resulting score is induced by the smoothed empirical distribution
μ ^ 0 ( γ ) = n n + γ μ 0 ( n ) + γ n + γ Unif ( X 0 ) , γ > 0 , (1) \widehat{\mu}_0^{(\gamma)} = \frac{n}{n+\gamma}\mu_0^{(n)} + \frac{\gamma}{n+\gamma}\operatorname{Unif}(\mathcal{X}_0), \qquad\gamma> 0, \tag*{(1)} μ 0 ( γ ) = n + γ n μ 0 ( n ) + n + γ γ Unif ( X 0 ) , γ > 0 , (1)
where μ 0 ( n ) \mu_0^{(n)} μ 0 ( n ) is the empirical law of the n n n training sequences. This distribution has full support, so it avoids the infinite forward KL loss that occurs when an estimator assigns zero probability to an unobserved sequence with positive data probability. The estimator in (1) does not depend on the corruption kernel; its forward marginals and associated scores do.
Smoothing discrete frequency estimates is classical. In particular, Mourtada (2026) analyzes an adaptive estimator of the form (1) and establishes sparse KL bounds and minimax lower bounds. Our contribution is to connect this estimation problem to regularized diffusion training and reverse sampling, and to determine how the smoothing level controls the resulting statistical error. For masked diffusion, this connection uses the conditional-distribution representation of the score established by Ou et al. [14 ] .
Our contributions can be summarized as follows:
In the setting of masked diffusion, we derive a method for regularizing scores via a context-dependent label smoothing. We show that this smoothing is equivalent to regularizing with the score loss of the uniform distribution, which extends it beyond masked diffusion. The optimal conditional predictions that minimize the regularized loss produce the proper score induced by (1).
We then establish expected and high-probability bounds for KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) \operatorname{KL}(\mu_{\mathrm{data}} \mid\widehat{\mu}_0^{(\gamma)}) KL ( μ data ∣ μ 0 ( γ ) ) in terms of the effective support and effective missing-support quantities of the data distribution, following the approach of Mourtada (2026). The bounds allow for data-dependent choices of γ \gamma γ , and the high-probability event holds simultaneously for every γ ∈ [ 1 , min { n , M } ] \gamma\in[1,\min\{n,M\}] γ ∈ [ 1 , min { n , M }] . They therefore describe the effect of regularization beyond exact support sparsity. We also identify ranges of smoothing levels that attain the sparse minimax rates.
We transfer these bounds to the terminal law ν ^ \widehat{\nu} ν of the reverse sampler. For the masked diffusion initialized at the fully masked state, we prove the exact identity ν ^ = μ ^ 0 ( γ ) \widehat{\nu} = \widehat{\mu}_0^{(\gamma)} ν = μ 0 ( γ ) . For uniform diffusion, we control the finite-horizon initialization error. With the adaptive choice γ = D n \gamma= D_n γ = D n , where D n D_n D n is the number of distinct training sequences, both noising procedures attain a sparse minimax rate of order l log ( e M / l ) / n l\log(eM/l)/n l log ( e M / l ) / n in expectation and high probability, without requiring knowledge of l l l or the support. Instead of depending on the size of the state space, which is exponentially large with respect to sequence length, the rate is instead governed by the sparsity l l l which can be far smaller in practice.
Relation to previous work. Recent analyses of discrete diffusion address several distinct statistical problems. Srikant et al. (2026) derive sample-complexity guarantees for neural score estimators, accounting for statistical, approximation, optimization, and clipping errors. Wakasugi & Suzuki (2025) obtain state-size-independent bounds by exploiting smooth embeddings and graph structure; their assumptions differ from support sparsity. Cho & Wu (2026) derive nearly matching minimax bounds for score estimation under the score-entropy loss and apply their analysis to both uniform and masked diffusion. Their bounds depend on the cardinality of the diffusion state space and on density-ratio bounds; they do not quantify adaptation to the support size of the clean distribution.
Closer to our setting, Zhang et al. [19 ] derive structure-dependent generalization bounds and compare the effects of sparsity under masked and uniform corruption. Such comparisons raise a further question: does the choice of corruption mechanism change the minimax risk over sparse data distributions? A difference between upper bounds for particular score estimators does not by itself establish a separation between the optimal risks. We address this question by analyzing a regularized score estimator and identifying the distribution generated by its reverse dynamics.
Notation. For a finite nonempty set I \mathcal{I} I , let ∣ I ∣ |\mathcal{I}| ∣ I ∣ denote its cardinality, P ( I ) \mathcal{P}(\mathcal{I}) P ( I ) denote the set of probability measures on I \mathcal{I} I , Unif ( I ) ∈ P ( I ) \operatorname{Unif}(\mathcal{I}) \in\mathcal{P}(\mathcal{I}) Unif ( I ) ∈ P ( I ) be its uniform law, δ x ∈ P ( I ) \delta_x \in\mathcal{P}(\mathcal{I}) δ x ∈ P ( I ) be the point mass at x ∈ I x \in\mathcal{I} x ∈ I . For x ∈ X x \in\mathcal{X} x ∈ X and A ⊆ [ d ] A \subseteq[d] A ⊆ [ d ] , write x A : = ( x j ) j ∈ A x_A := (x_j)_{j \in A} x A := ( x j ) j ∈ A and x − i : = x [ d ] ∖ { i } x_{-i} := x_{[d]\setminus\{i\}} x − i := x [ d ] ∖ { i } . For μ , ν ∈ P ( I ) \mu,\nu\in\mathcal{P}(\mathcal{I}) μ , ν ∈ P ( I ) , define KL ( μ ∣ ν ) : = ∑ x : μ ( x ) > 0 μ ( x ) log ( μ ( x ) / ν ( x ) ) \operatorname{KL}(\mu\mid\nu) := \sum_{x:\mu(x)>0} \mu(x) \log(\mu(x)/\nu(x)) KL ( μ ∣ ν ) := ∑ x : μ ( x ) > 0 μ ( x ) log ( μ ( x ) / ν ( x )) , when μ ≪ ν \mu\ll\nu μ ≪ ν , and set KL ( μ ∣ ν ) : = + ∞ \operatorname{KL}(\mu\mid\nu) := +\infty KL ( μ ∣ ν ) := + ∞ otherwise. Given any positive integer K K K , we use the shorthand [ K ] = { 1 , … , K } [K] = \{1,\ldots,K\} [ K ] = { 1 , … , K } and we use the notation a ≲ b a \lesssim b a ≲ b to mean a ≤ C b a \le Cb a ≤ C b for a universal constant C C C .
Preliminaries
We consider the problem of density estimation for a target distribution μ d a t a ∈ P ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}(\mathcal{X}_0) μ data ∈ P ( X 0 ) on the finite sequence space, X 0 : = V d \mathcal{X}_0 := \mathcal{V}^d X 0 := V d , d ≥ 1 d \ge1 d ≥ 1 . Without loss of generality, we take V : = [ K ] \mathcal{V} := [K] V := [ K ] with K ≥ 2 K \ge2 K ≥ 2 leading to a cardinality M : = ∣ X 0 ∣ = K d M := |\mathcal{X}_0| = K^d M := ∣ X 0 ∣ = K d that grows exponentially with d d d .
Discrete diffusion models. The goal of discrete diffusion models is to learn a generative model that approximates μ d a t a \mu_{\mathrm{data}} μ data with access to only a finite set of samples S = ( X 0 ( 1 ) , … , X 0 ( n ) ) ∼ μ d a t a ⊗ n S = (X_0^{(1)}, \ldots, X_0^{(n)}) \sim\mu_{\mathrm{data}}^{\otimes n} S = ( X 0 ( 1 ) , … , X 0 ( n ) ) ∼ μ data ⊗ n . This is done by simulating the reversal of a Markov process that starts from the data distribution and converges to a tractable limiting distribution. For convenience of exposition, we define this Markov process on a larger finite set X ⊇ X 0 \mathcal{X} \supseteq\mathcal{X}_0 X ⊇ X 0 and we identify μ d a t a \mu_{\mathrm{data}} μ data with its extension by zero to X \mathcal{X} X .
The forward process is defined as a continuous-time Markov chain ( X t ) t ∈ [ 0 , T ] (X_t)_{t \in[0,T]} ( X t ) t ∈ [ 0 , T ] on X \mathcal{X} X with time horizon T > 0 T > 0 T > 0 and rate matrix ( Q t ) t ∈ [ 0 , T ] (Q_t)_{t \in[0,T]} ( Q t ) t ∈ [ 0 , T ] (throughout this work we use the column-generator convention—details in Appendix A.1). We assume that Q t = σ t Q 0 Q_t = \sigma_t Q_0 Q t = σ t Q 0 where Q 0 Q_0 Q 0 is a fixed conservative generator and σ : [ 0 , ∞ ) → [ 0 , ∞ ) \sigma: [0,\infty) \to[0,\infty) σ : [ 0 , ∞ ) → [ 0 , ∞ ) is integrable with σ ˉ t : = ∫ 0 t σ u d u \bar{\sigma}_t := \int_0^t \sigma_u\,du σ ˉ t := ∫ 0 t σ u d u satisfying $0 < \bar{\sigma}_t < \infty$ for all t > 0 t > 0 t > 0 , and σ ˉ t → ∞ \bar{\sigma}_t \to\infty σ ˉ t → ∞ as t → ∞ t \to\infty t → ∞ . For $0 \le s \le t \le T$, x , y ∈ X x,y \in\mathcal{X} x , y ∈ X , we define the transition matrix P s , t ( x , y ) : = P ( X t = x ∣ X s = y ) P_{s,t}(x,y) := \mathbb{P}(X_t = x \mid X_s = y) P s , t ( x , y ) := P ( X t = x ∣ X s = y ) which satisfies,
P s , t = exp ( ( σ ˉ t − σ ˉ s ) Q 0 ) . (2) P_{s,t} = \exp\left((\bar{\sigma}_t-\bar{\sigma}_s)Q_0\right). \tag*{(2)} P s , t = exp ( ( σ ˉ t − σ ˉ s ) Q 0 ) . (2)
In particular, if μ t ( x ) : = P ( X t = x ) \mu_t(x) := \mathbb{P}(X_t = x) μ t ( x ) := P ( X t = x ) , then μ t \mu_t μ t solves the forward Kolmogorov equation,
∂ t μ t ( x ) = Q t μ t ( x ) = ∑ y ∈ X Q t ( x , y ) μ t ( y ) . (3) \partial_t\mu_t(x) = Q_t\mu_t(x) = \sum_{y \in\mathcal{X}} Q_t(x,y)\mu_t(y). \tag*{(3)} ∂ t μ t ( x ) = Q t μ t ( x ) = y ∈ X ∑ Q t ( x , y ) μ t ( y ) . (3)
We initialize the process at the data distribution μ 0 = μ d a t a \mu_0 = \mu_{\mathrm{data}} μ 0 = μ data so that, by definition, μ t = P 0 , t μ d a t a \mu_t = P_{0,t}\mu_{\mathrm{data}} μ t = P 0 , t μ data .
The reverse process. The time-reversed process, which we define by X ~ t : = X T − t \widetilde{X}_t := X_{T-t} X t := X T − t , t ∈ [ 0 , T ] t \in[0,T] t ∈ [ 0 , T ] , is also a continuous-time Markov chain whose rate matrix Q ~ t ( x , y ) \widetilde{Q}_t(x,y) Q t ( x , y ) satisfies the identity, μ T − t ( y ) Q ~ t ( x , y ) = μ T − t ( x ) Q T − t ( y , x ) \mu_{T-t}(y)\widetilde{Q}_t(x,y) = \mu_{T-t}(x)Q_{T-t}(y,x) μ T − t ( y ) Q t ( x , y ) = μ T − t ( x ) Q T − t ( y , x ) whenever x ≠ y x \ne y x = y , μ T − t ( y ) > 0 \mu_{T-t}(y) > 0 μ T − t ( y ) > 0 (see, e.g., [6 Theorem 2.8] ). This motivates the definition of the discrete score,
s ⋆ ( x , y , t ) : = { μ t ( x ) μ t ( y ) , μ t ( y ) > 0 , 0 , μ t ( y ) = 0 , (4) s^\star(x,y,t) :=
\begin{cases}
\frac{\mu_t(x)}{\mu_t(y)}, & \mu_t(y)>0,\\
0, & \mu_t(y)=0,
\end{cases} \tag*{(4)} s ⋆ ( x , y , t ) := { μ t ( y ) μ t ( x ) , 0 , μ t ( y ) > 0 , μ t ( y ) = 0 , (4)
and hence, for x ≠ y x \ne y x = y , the reverse generator can be written as Q ~ t ( x , y ) = s ⋆ ( x , y , T − t ) Q T − t ( y , x ) \widetilde{Q}_t(x,y) = s^\star(x,y,T-t)Q_{T-t}(y,x) Q t ( x , y ) = s ⋆ ( x , y , T − t ) Q T − t ( y , x ) with diagonal entries chosen so that the columns sum to zero. Equivalently, the reverse marginal law μ ~ t \widetilde{\mu}_t μ t solves
∂ t μ ~ t = Q ~ t μ ~ t , μ ~ 0 = μ T . (5) \partial_t\widetilde{\mu}_t = \widetilde{Q}_t\widetilde{\mu}_t,\qquad\widetilde{\mu}_0 = \mu_T. \tag*{(5)} ∂ t μ t = Q t μ t , μ 0 = μ T . (5)
With this initialization, we have that μ ~ t = μ T − t \widetilde{\mu}_t = \mu_{T-t} μ t = μ T − t , and thus, exact sampling from the reverse process would recover the data distribution, μ ~ T = μ d a t a \widetilde{\mu}_T = \mu_{\mathrm{data}} μ T = μ data .
In practice, the ratios s ⋆ s^\star s ⋆ are unknown and must be estimated by some estimator score s ( x , y , t ) s(x,y,t) s ( x , y , t ) . We assume that this score is integrable in t t t and positive in the triple ( x , y , t ) (x,y,t) ( x , y , t ) where Q t ( y , x ) > 0 Q_t(y,x) > 0 Q t ( y , x ) > 0 . We then define the associated generator Q ^ t ( x , y ) \widehat{Q}_t(x,y) Q t ( x , y ) as Q ~ t ( x , y ) \widetilde{Q}_t(x,y) Q t ( x , y ) , but with s ( x , y , T − t ) s(x,y,T-t) s ( x , y , T − t ) in place of s ⋆ ( x , y , T − t ) s^\star(x,y,T-t) s ⋆ ( x , y , T − t ) . We also do not have access to the initial distribution μ ~ 0 = μ T \widetilde{\mu}_0 = \mu_T μ 0 = μ T so we initialize at some tractable distribution μ ∞ ∈ P ( X ) \mu_\infty\in\mathcal{P}(\mathcal{X}) μ ∞ ∈ P ( X ) which is usually set to be a stationary distribution of the forward process. We define the sampling process on [ 0 , T ) [0,T) [ 0 , T ) as the one which evolves according to
∂ t ν t = Q ^ t ν t , ν 0 = μ ∞ . (6) \partial_t\nu_t = \widehat{Q}_t\nu_t,\qquad\nu_0 = \mu_\infty. \tag*{(6)} ∂ t ν t = Q t ν t , ν 0 = μ ∞ . (6)
We will only use two choices of Q 0 Q_0 Q 0 , corresponding to the uniform and masked noising processes, though we expect that our results may be adapted to other settings; see Appendix § 7 .§ 1 for details. For the uniform process, we set X = X 0 \mathcal{X} = \mathcal{X}_0 X = X 0 and consider a rate matrix with identical positive values on the off-diagonal, leading to a process that converges to the uniform measure. Therefore, in this case we set μ ∞ = Unif ( X ) \mu_\infty= \operatorname{Unif}(\mathcal{X}) μ ∞ = Unif ( X ) . For the absorbing or masked process, we extend the space X = ( V ∪ { m } ) d \mathcal{X} = (\mathcal{V} \cup\{m\})^d X = ( V ∪ { m } ) d , where m ∉ V m \notin\mathcal{V} m ∈ / V is a mask token that the forward process converges to. In this case, we set μ ∞ = δ ( m , … , m ) \mu_\infty= \delta_{(m,\ldots,m)} μ ∞ = δ ( m , … , m ) .
Score-entropy loss. Following Lou et al. [11 ] , in order to find the estimator s s s , we utilize the score-entropy loss, which is defined for the weights w t ( x , y ) ≥ 0 w_t(x,y) \ge0 w t ( x , y ) ≥ 0 by,
L t ( s ) : = E y ∼ μ t [ ∑ x ≠ y w t ( x , y ) ( s ( x , y , t ) − s ⋆ ( x , y , t ) log s ( x , y , t ) + ϕ ( s ⋆ ( x , y , t ) ) ) ] , (7) \mathcal{L}_t(s) := \mathbb{E}_{y\sim\mu_t}\left[\sum_{x\ne y} w_t(x,y)\left(s(x,y,t)-s^\star(x,y,t)\log s(x,y,t)+\phi(s^\star(x,y,t))\right)\right], \tag*{(7)} L t ( s ) := E y ∼ μ t x = y ∑ w t ( x , y ) ( s ( x , y , t ) − s ⋆ ( x , y , t ) log s ( x , y , t ) + ϕ ( s ⋆ ( x , y , t )) ) , (7)
where ϕ ( x ) : = x ( log x − 1 ) \phi(x) := x(\log x - 1) ϕ ( x ) := x ( log x − 1 ) , with ϕ ( 0 ) = 0 \phi(0) = 0 ϕ ( 0 ) = 0 . Throughout, we take w t ( x , y ) = Q t ( y , x ) w_t(x,y) = Q_t(y,x) w t ( x , y ) = Q t ( y , x ) , following the literature, for example see Zhang et al., [19 ] . In practice, we consider its empirical counterpart,
L ^ t ( s ) : = 1 n ∑ i = 1 n E y ∼ P 0 , t ( ⋅ , X 0 ( i ) ) [ ∑ x ≠ y Q t ( y , x ) ( s ( x , y , t ) − P 0 , t ( x , X 0 ( i ) ) P 0 , t ( y , X 0 ( i ) ) log s ( x , y , t ) ) ] , (8) \widehat{\mathcal{L}}_t(s) := \frac{1}{n}\sum_{i=1}^{n}\mathbb{E}_{y\sim P_{0,t}(\cdot,X_0^{(i)})}\left[\sum_{x\ne y}Q_t(y,x)\left(s(x,y,t)-\frac{P_{0,t}(x,X_0^{(i)})}{P_{0,t}(y,X_0^{(i)})}\log s(x,y,t)\right)\right], \tag*{(8)} L t ( s ) := n 1 i = 1 ∑ n E y ∼ P 0 , t ( ⋅ , X 0 ( i ) ) x = y ∑ Q t ( y , x ) ( s ( x , y , t ) − P 0 , t ( y , X 0 ( i ) ) P 0 , t ( x , X 0 ( i ) ) log s ( x , y , t ) ) , (8)
which is the score-entropy loss for the empirical law μ 0 ( n ) : = n − 1 ∑ j = 1 n δ X 0 ( j ) \mu_0^{(n)} := n^{-1}\sum_{j=1}^{n}\delta_{X_0^{(j)}} μ 0 ( n ) := n − 1 ∑ j = 1 n δ X 0 ( j ) .
l l l -sparsity and lower bounds. In this work, we consider the class of l l l -sparse distributions. In particular, for a fixed integer l l l such that 1 ≤ l ≤ ∣ X 0 ∣ 1 \le l \le|\mathcal{X}_0| 1 ≤ l ≤ ∣ X 0 ∣ , we define the class by,
P l ( X 0 ) : = { μ ∈ P ( X 0 ) : ∣ supp ( μ ) ∣ ≤ l } . (9) \mathcal{P}_l(\mathcal{X}_0) := \{\mu\in\mathcal{P}(\mathcal{X}_0) : |\operatorname{supp}(\mu)| \le l\}. \tag*{(9)} P l ( X 0 ) := { μ ∈ P ( X 0 ) : ∣ supp ( μ ) ∣ ≤ l } . (9)
In this paper, we are interested in showing minimax rates for sparse density estimation and so we recall some lower bounds for the problem. This problem has been widely studied [9 , 10 ] , though we focus on the following recent result of Mourtada [12 ] . Whenever n , ∣ X ∣ ≥ 110 n, |\mathcal{X}| \ge110 n , ∣ X ∣ ≥ 110 , δ ∈ ( e − n , e − 2 ) \delta\in(e^{-n}, e^{-2}) δ ∈ ( e − n , e − 2 ) , 2 ≤ l ≤ min { n , ∣ X ∣ / 55 } 2 \le l \le\min\{n, |\mathcal{X}|/55\} 2 ≤ l ≤ min { n , ∣ X ∣/55 } , for any estimator Φ : X n → P ( X ) \Phi: \mathcal{X}^n \to\mathcal{P}(\mathcal{X}) Φ : X n → P ( X ) , there exists a distribution P ∈ P l ( X ) P \in\mathcal{P}_l(\mathcal{X}) P ∈ P l ( X ) such that,
P P ( KL ( P ∥ P ^ n ) ≥ l log ( e ∣ X ∣ / l ) + log ( ∣ X ∣ ) log ( 1 / δ ) 320 n ) ≥ δ . (10) \mathbb{P}_P\left(\operatorname{KL}(P\Vert\widehat{P}_n) \ge\frac{l\log(e|\mathcal{X}|/l) + \log(|\mathcal{X}|)\log(1/\delta)}{320n}\right) \ge\delta. \tag*{(10)} P P ( KL ( P ∥ P n ) ≥ 320 n l log ( e ∣ X ∣/ l ) + log ( ∣ X ∣ ) log ( 1/ δ ) ) ≥ δ . (10)
where P ^ n = Φ ( X 1 , … , X n ) \widehat{P}_n = \Phi(X_1,\ldots,X_n) P n = Φ ( X 1 , … , X n ) . From this, we immediately obtain bounds in expectation,
E [ KL ( P ∥ P ^ n ) ] ≥ l log ( e ∣ X ∣ / l ) 320 e 2 n . \mathbb{E}[\operatorname{KL}(P\Vert\widehat{P}_n)] \ge\frac{l\log(e|\mathcal{X}|/l)}{320e^{2n}}. E [ KL ( P ∥ P n )] ≥ 320 e 2 n l log ( e ∣ X ∣/ l ) .
Further results from Mourtada [12 ] can be found in Appendix § 7 .§ 2 .
Statistical rates for masked diffusion
The goal of our analysis is to derive bounds for KL ( μ d a t a ∥ ν ^ ) \operatorname{KL}(\mu_{\mathrm{data}}\Vert\widehat{\nu}) KL ( μ data ∥ ν ) where we define ν ^ : = lim u → T ν u \widehat{\nu}:=\lim_{u\to T}\nu_u ν := lim u → T ν u , and ν u \nu_u ν u is the solution of (6) . In order to do this, we derive a particular choice of estimator s ( x , y , t ) s(x,y,t) s ( x , y , t ) , then we obtain upper bounds on KL ( μ d a t a ∥ ν ^ ) \operatorname{KL}(\mu_{\mathrm{data}}\Vert\widehat{\nu}) KL ( μ data ∥ ν ) as a function of a tuning parameter γ \gamma γ which we then compare with minimax lower bounds for the sparse distribution class. With this, we find two intervals for γ \gamma γ , one for the bound in expectation and one for the bound in high-probability, for which we reach the minimax optimal rates for the sparse distribution class.
Throughout this section, we denote by S S S our i.i.d. dataset, and denote by E S \mathbb{E}_S E S and P S \mathbb{P}_S P S the expectation and the probability with respect to the dataset. In the following, we begin with a problem of minimizing the empirical risk, which is a standard object of study in the training of discrete diffusion models. However, in the present setting, we cannot directly use the minimizer as it produces a score with infinite KL divergence. Thus, we look for non-parametric methods for regularizing the empirical problem.
Label smoothing for discrete scores
We first motivate our approach to regularizing the score by relating the score matching problem to classification. We define a context to be a triple c = ( A , v , i ) c=(A,v,i) c = ( A , v , i ) where A ⊆ [ d ] A\subseteq[d] A ⊆ [ d ] , v ∈ V A v\in\mathcal{V}^{A} v ∈ V A and i ∈ [ d ] ∖ A i\in[d]\setminus A i ∈ [ d ] ∖ A , and for a partially masked state y y y with masked position i i i we write c ( y , i ) : = ( A ( y ) , y A ( y ) , i ) c(y,i):=(A(y),y_{A(y)},i) c ( y , i ) := ( A ( y ) , y A ( y ) , i ) . In Ou et al. [14 ] , it was first shown that the score function s ∗ s^* s ∗ for the masked diffusion admits the factorization,
s ∗ ( x , y , t ) = κ t ψ c ( y , i ) ∗ ( x i ) , κ t : = α t 1 − α t , (11) s^*(x,y,t)=\kappa_t\psi^*_{c(y,i)}(x_i),\qquad\kappa_t:=\frac{\alpha_t}{1-\alpha_t}, \tag*{(11)} s ∗ ( x , y , t ) = κ t ψ c ( y , i ) ∗ ( x i ) , κ t := 1 − α t α t , (11)
where ψ c ∗ ( a ) : = μ d a t a ( X i = a ∣ X A = v ) \psi^*_c(a):=\mu_{\mathrm{data}}(X_i=a\mid X_A=v) ψ c ∗ ( a ) := μ data ( X i = a ∣ X A = v ) is the conditional law of the clean token (see Proposition 2). Thus, the time dependence of the score can be obtained in closed-form, and the only quantity to learn is ψ c ∗ \psi^*_c ψ c ∗ , which can be viewed as a classifier that predicts the token at position i i i from the unmasked tokens v v v . We thus parametrize the score estimator as s ( x , y , t ) = κ t ψ c ( y , i ) ( x i ) s(x,y,t)=\kappa_t\psi_{c(y,i)}(x_i) s ( x , y , t ) = κ t ψ c ( y , i ) ( x i ) with ψ c ( y , i ) ∈ P ( V ) \psi_{c(y,i)}\in\mathcal{P}(\mathcal{V}) ψ c ( y , i ) ∈ P ( V ) which is also a parameterization used in practice, where the score network outputs a softmax over V \mathcal{V} V at each masked position.
To take this analogue further, we can also describe the score-entropy loss via the cross-entropy. Let n c : = ∣ { k : X 0 , A ( k ) = v } ∣ n_c:=|\{k:X^{(k)}_{0,A}=v\}| n c := ∣ { k : X 0 , A ( k ) = v } ∣ , and let ψ c ( n ) \psi_c^{(n)} ψ c ( n ) be the conditional distribution for the empirical data distribution, ψ c ( n ) ( a ) : = μ 0 ( n ) ( X i = a ∣ X A = v ) \psi_c^{(n)}(a):=\mu_0^{(n)}(X_i=a\mid X_A=v) ψ c ( n ) ( a ) := μ 0 ( n ) ( X i = a ∣ X A = v ) . Plugging (11) into (8) , it can be easily shown that
∫ 0 T L ^ t ( s ) d t = ∑ c ω ∣ A ∣ n c n H ( ψ c ( n ) , ψ c ) + c o n s t , (12) \int_0^T \widehat{\mathcal{L}}_t(s)\,\mathrm{d}t=\sum_c\omega_{|A|}\frac{n_c}{n}H(\psi_c^{(n)},\psi_c)+\mathrm{const}, \tag*{(12)} ∫ 0 T L t ( s ) d t = c ∑ ω ∣ A ∣ n n c H ( ψ c ( n ) , ψ c ) + const , (12)
where H ( p , q ) : = − ∑ a p ( a ) log q ( a ) H(p,q):=-\sum_a p(a)\log q(a) H ( p , q ) := − ∑ a p ( a ) log q ( a ) is the cross-entropy and the weights ω k > 0 \omega_k>0 ω k > 0 depend only on k k k and T T T . The minimizer of (12) is the empirical conditional ψ c ( n ) \psi_c^{(n)} ψ c ( n ) on every observed context, while contexts with n c = 0 n_c=0 n c = 0 are left unconstrained.
By viewing ψ c \psi_c ψ c as a classifier trained with the cross-entropy loss, a natural choice of regularization is label smoothing (Szegedy et al. [17 ] ). In classification, label smoothing adds the penalty H ( Unif , ⋅ ) H(\operatorname{Unif},\cdot) H ( Unif , ⋅ ) to the loss to reduce confidence in predictions and prevent overfitting. We thus add a label smoothing penalty to each classifier with a context-dependent parameter ε c ∈ [ 0 , 1 ] \varepsilon_c \in[0,1] ε c ∈ [ 0 , 1 ] :
( 1 − ε c ) H ( ψ c ( n ) , ψ c ) + ε c H ( Unif ( V ) , ψ c ) . (13) (1-\varepsilon_c)H(\psi_c^{(n)},\psi_c)+\varepsilon_c H(\operatorname{Unif}(\mathcal{V}),\psi_c). \tag*{(13)} ( 1 − ε c ) H ( ψ c ( n ) , ψ c ) + ε c H ( Unif ( V ) , ψ c ) . (13)
By linearity of the cross-entropy in the first argument, we have that this is minimized by, ψ ^ c = ( 1 − ε c ) ψ c ( n ) + ε c Unif ( V ) \hat{\psi}_c=(1-\varepsilon_c)\psi_c^{(n)}+\varepsilon_c\operatorname{Unif}(\mathcal{V}) ψ ^ c = ( 1 − ε c ) ψ c ( n ) + ε c Unif ( V ) .
Note that for a generic choice of ε c \varepsilon_c ε c , it is not clear that the score function resulting from label smoothing will necessarily produce a proper score: that is, a score s s s that relates to a diffusion for a probability measure μ s \mu_s μ s . In the following lemma, we show that there is a class of such choices of ε c \varepsilon_c ε c and that this class produces a smoothing of the empirical measure.
Lemma 1. Suppose that for every i ∈ [ d ] i\in[d] i ∈ [ d ] , there exists b i ∈ V b_i\in\mathcal{V} b i ∈ V such that μ d a t a ( X i = b i ) = 0 \mu_{\mathrm{data}}(X_i=b_i)=0 μ data ( X i = b i ) = 0 , and that ε c = 1 \varepsilon_c=1 ε c = 1 for every context c = ( A , v , i ) c=(A,v,i) c = ( A , v , i ) with n c = 0 n_c=0 n c = 0 . Then, the score function s ( x , y , t ) : = κ t ψ ^ c ( y , i ) ( x i ) s(x,y,t):=\kappa_t\hat{\psi}_{c(y,i)}(x_i) s ( x , y , t ) := κ t ψ ^ c ( y , i ) ( x i ) is proper if and only if there exists γ ∈ ( 0 , ∞ ] \gamma\in(0,\infty] γ ∈ ( 0 , ∞ ] , not depending on c c c , such that
ε c = γ K − ∣ A ∣ γ K − ∣ A ∣ + n c , for every context c = ( A , v , i ) , (14) \varepsilon_c=\frac{\gamma K^{-|A|}}{\gamma K^{-|A|}+n_c},\qquad\text{for every context }c=(A,v,i), \tag*{(14)} ε c = γ K − ∣ A ∣ + n c γ K − ∣ A ∣ , for every context c = ( A , v , i ) , (14) where ε c : = 1 \varepsilon_c:=1 ε c := 1 if γ = ∞ \gamma=\infty γ = ∞ . In particular, s s s is the proper score induced by the terminal law, μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) .
We see that the smoothing is as in Szegedy et al. (2016), but where the level of smoothing ε c \varepsilon_c ε c decreases with the number of observations n c n_c n c of the context rather than being fixed. In particular, contexts that are observed frequently are barely smoothed, and contexts that do not appear in the sample are predicted uniformly. For this choice of ε c \varepsilon_c ε c , we find an elegant relationship between label smoothing and the score entropy loss relative to the uniform sequence distribution, L U \mathcal{L}^U L U . In particular, for the mixed loss L ^ t M ( s ) = ( 1 − γ n + γ ) L ^ t ( s ) + γ n + γ L t U ( s ) \hat{\mathcal{L}}^M_t(s)=(1-\frac{\gamma}{n+\gamma})\hat{\mathcal{L}}_t(s)+\frac{\gamma}{n+\gamma}\mathcal{L}^U_t(s) L ^ t M ( s ) = ( 1 − n + γ γ ) L ^ t ( s ) + n + γ γ L t U ( s ) , we have,
∫ 0 T L ^ t M ( s ) d t = ∑ c ω ∣ A ∣ n c + γ K − ∣ A ∣ n + γ ( ( 1 − ε c ) H ( ψ c ( n ) , ψ c ) + ε c H ( Unif ( V ) , ψ c ) ) + c o n s t , \int_0^T\hat{\mathcal{L}}^M_t(s)\,\mathrm{d}t
=\sum_c\omega_{|A|}\frac{n_c+\gamma K^{-|A|}}{n+\gamma}
\left((1-\varepsilon_c)H(\psi_c^{(n)},\psi_c)+\varepsilon_c H(\operatorname{Unif}(\mathcal{V}),\psi_c)\right)+\mathrm{const}, ∫ 0 T L ^ t M ( s ) d t = c ∑ ω ∣ A ∣ n + γ n c + γ K − ∣ A ∣ ( ( 1 − ε c ) H ( ψ c ( n ) , ψ c ) + ε c H ( Unif ( V ) , ψ c ) ) + const ,
as shown in Lemma 8.
For the statistical analysis pursued in this work, we take this class of proper label-smoothed score functions as the estimator which we analyze. In particular,
s ^ ( γ ) ( x , y , t ) : = κ t ( ( 1 − ε c ) ψ c ( n ) ( x i ) + ε c Unif ( V ) ) , ε c = γ K − ∣ A ∣ γ K − ∣ A ∣ + n c , (15) \hat{s}^{(\gamma)}(x,y,t):=\kappa_t\left((1-\varepsilon_c)\psi_c^{(n)}(x_i)+\varepsilon_c\operatorname{Unif}(\mathcal{V})\right),\qquad
\varepsilon_c=\frac{\gamma K^{-|A|}}{\gamma K^{-|A|}+n_c}, \tag*{(15)} s ^ ( γ ) ( x , y , t ) := κ t ( ( 1 − ε c ) ψ c ( n ) ( x i ) + ε c Unif ( V ) ) , ε c = γ K − ∣ A ∣ + n c γ K − ∣ A ∣ , (15)
In the sections to follow, we analyze this estimator and show that for an appropriately tuned γ \gamma γ , we obtain minimax optimal rates in sparse settings.
Upper bounds
We now proceed with the statistical analysis of the estimator introduced above. To begin with, we introduce two fundamental data-dependent quantities that we borrow from [12 ] and use in our analysis.
Definition 1. Given a probability distribution μ \mu μ , let us define the effective support size k e f f ( μ , n ) k_{\mathrm{eff}}(\mu,n) k eff ( μ , n ) of μ \mu μ at a sample size n n n as
k e f f ( μ , n ) : = ∑ x ∈ X 0 min { 1 , n μ ( x ) } = ∣ { x ∈ X 0 : μ ( x ) ≥ 1 / n } ∣ + ∑ x : μ ( x ) < 1 / n n μ ( x ) . (16) k_{\mathrm{eff}}(\mu,n):=\sum_{x\in\mathcal{X}_0}\min\{1,n\mu(x)\}
=\left|\{x\in\mathcal{X}_0:\mu(x)\ge1/n\}\right|
+\sum_{x:\mu(x)<1/n}n\mu(x). \tag*{(16)} k eff ( μ , n ) := x ∈ X 0 ∑ min { 1 , n μ ( x )} = ∣ { x ∈ X 0 : μ ( x ) ≥ 1/ n } ∣ + x : μ ( x ) < 1/ n ∑ n μ ( x ) . (16)
Similarly, we define the effective missing support size k e f f ∘ ( μ , n ) k_{\mathrm{eff}}^{\circ}(\mu,n) k eff ∘ ( μ , n ) of μ \mu μ with sample size n n n as
k e f f ∘ ( μ , n ) : = ∑ x ∈ X 0 min { exp ( 1 − n μ ( x ) ) , n μ ( x ) } = ∑ x : μ ( x ) ≥ 1 / n exp ( 1 − n μ ( x ) ) + ∑ x : μ ( x ) < 1 / n n μ ( x ) . (17) k_{\mathrm{eff}}^{\circ}(\mu,n) := \sum_{x\in\mathcal{X}_0} \min\{\exp(1-n\mu(x)),n\mu(x)\} = \sum_{x:\mu(x)\geq1/n}\exp(1-n\mu(x))+\sum_{x:\mu(x)<1/n}n\mu(x). \tag*{(17)} k eff ∘ ( μ , n ) := x ∈ X 0 ∑ min { exp ( 1 − n μ ( x )) , n μ ( x )} = x : μ ( x ) ≥ 1/ n ∑ exp ( 1 − n μ ( x )) + x : μ ( x ) < 1/ n ∑ n μ ( x ) . (17)
The quantity k e f f ( μ , n ) / n k_{\mathrm{eff}}(\mu,n)/n k eff ( μ , n ) / n relates to error in the empirical measure due to low probability sequences that will likely be missing from the dataset. We note that k e f f ( μ , n ) k_{\mathrm{eff}}(\mu,n) k eff ( μ , n ) is increasing with n n n while k e f f ( μ , n ) / n k_{\mathrm{eff}}(\mu,n)/n k eff ( μ , n ) / n is decreasing. Also, k e f f ( μ , 1 ) = 1 k_{\mathrm{eff}}(\mu,1)=1 k eff ( μ , 1 ) = 1 , k e f f ( μ , n ) ≤ l k_{\mathrm{eff}}(\mu,n)\leq l k eff ( μ , n ) ≤ l if μ ∈ P l \mu\in\mathcal{P}_l μ ∈ P l , and k e f f ( μ , n ) k_{\mathrm{eff}}(\mu,n) k eff ( μ , n ) converges to k e f f ( μ , ∞ ) = supp ( μ ) k_{\mathrm{eff}}(\mu,\infty)=\operatorname{supp}(\mu) k eff ( μ , ∞ ) = supp ( μ ) as n → ∞ n\to\infty n → ∞ .
We now provide two important lemmas which upper bound the KL between μ d a t a \mu_{\mathrm{data}} μ data and μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) . Throughout this section, we require that γ \gamma γ is a measurable map from X 0 n \mathcal{X}_0^n X 0 n to [ 1 , min { n , K d } ] [1,\min\{n,K^d\}] [ 1 , min { n , K d }] . For the sake of brevity, we denote by μ ^ 0 \hat{\mu}_0 μ ^ 0 , k e f f k_{\mathrm{eff}} k eff , L γ L_\gamma L γ the objects μ ^ 0 ( γ ( S ) ) \hat{\mu}_0^{(\gamma(S))} μ ^ 0 ( γ ( S )) , k e f f ( μ d a t a , n ) k_{\mathrm{eff}}(\mu_{\mathrm{data}},n) k eff ( μ data , n ) and log e K d γ \log\frac{eK^d}{\gamma} log γ e K d , respectively.
Lemma 2. If n ≥ 8 n\geq8 n ≥ 8 , then for every deterministic γ 0 ∈ [ 1 , min { n , K d } ] \gamma_0\in[1,\min\{n,K^d\}] γ 0 ∈ [ 1 , min { n , K d }] ,
E S KL ( μ d a t a ∣ μ ^ 0 ) ≤ C k e f f + E S [ γ ] + k e f f ∘ ( μ d a t a , n / 8 ) L γ 0 n + log ( γ 0 ) P S ( γ < γ 0 ) , (18) \mathbb{E}_S\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0)\leq C\frac{k_{\mathrm{eff}}+\mathbb{E}_S[\gamma]+k_{\mathrm{eff}}^{\circ}(\mu_{\mathrm{data}},n/8)L_{\gamma_0}}{n}+\log(\gamma_0)\mathbb{P}_S(\gamma<\gamma_0), \tag*{(18)} E S KL ( μ data ∣ μ ^ 0 ) ≤ C n k eff + E S [ γ ] + k eff ∘ ( μ data , n /8 ) L γ 0 + log ( γ 0 ) P S ( γ < γ 0 ) , (18) for some universal constant C > 0 C>0 C > 0 .
Lemma 3. If n ≥ 13 n\geq13 n ≥ 13 , K d ≥ 3 K^d\geq3 K d ≥ 3 and δ ∈ ( e − n / 6 , e − 2 ) \delta\in(e^{-n/6},e^{-2}) δ ∈ ( e − n /6 , e − 2 ) , there is an event A A A with P S ( A ) ≥ 1 − 12 δ \mathbb{P}_S(A)\geq1-12\delta P S ( A ) ≥ 1 − 12 δ , defined in terms of S S S and independent of γ \gamma γ , on which, simultaneously for every γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] ,
KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) ≤ C k e f f + γ + k e f f ∘ ( μ d a t a , n / 112 ) L γ + ( 1 + L γ ) log 1 δ + log 1 δ log log 1 δ n , \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)})\leq C\frac{k_{\mathrm{eff}}+\gamma+k_{\mathrm{eff}}^{\circ}(\mu_{\mathrm{data}},n/112)L_\gamma+(1+L_\gamma)\log\frac{1}{\delta}+\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}, KL ( μ data ∣ μ ^ 0 ( γ ) ) ≤ C n k eff + γ + k eff ∘ ( μ data , n /112 ) L γ + ( 1 + L γ ) log δ 1 + log δ 1 log log δ 1 , for some universal constant C > 0 C>0 C > 0 .
We note that if γ 0 = 1 \gamma_0=1 γ 0 = 1 , the term log ( γ 0 ) P ( γ < γ 0 ) = 0 \log(\gamma_0)\mathbb{P}(\gamma<\gamma_0)=0 log ( γ 0 ) P ( γ < γ 0 ) = 0 , but the term L γ 0 L_{\gamma_0} L γ 0 takes the maximum value of 1 + d log K 1+d\log K 1 + d log K . Thus, we have a trade off, which will be optimized depending on the setting.
The lemmas above provide bounds, both in expectation and in high probability, on the KL divergence between μ d a t a \mu_{\mathrm{data}} μ data and the smoothed empirical distribution μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) . However, to analyze the diffusion model, we must instead consider ν t \nu_t ν t . We do this via the following lemma.
Lemma 4. Let γ > 0 \gamma>0 γ > 0 , let μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) be as in (1) and s ^ = s ^ ( γ ) \hat{s}=\hat{s}^{(\gamma)} s ^ = s ^ ( γ ) as in (15). Then (6) with score s ^ \hat{s} s ^ and initial law δ ( m , … , m ) \delta_{(m,\ldots,m)} δ ( m , … , m ) has a unique absolutely continuous solution ( ν u ) u ∈ [ 0 , T ) (\nu_u)_{u\in[0,T)} ( ν u ) u ∈ [ 0 , T ) , the limit ν ^ : = lim u ↑ T ν u \hat{\nu}:=\lim_{u\uparrow T}\nu_u ν ^ := lim u ↑ T ν u exists, and ν ^ = μ ^ 0 ( γ ) \hat{\nu}=\hat{\mu}_0^{(\gamma)} ν ^ = μ ^ 0 ( γ ) , where μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) is extended by zero to X \mathcal{X} X : ν ^ ( x ) = μ ^ 0 ( γ ) ( x ) \hat{\nu}(x)=\hat{\mu}_0^{(\gamma)}(x) ν ^ ( x ) = μ ^ 0 ( γ ) ( x ) for x ∈ X 0 x\in\mathcal{X}_0 x ∈ X 0 and ν ^ ( x ) = 0 \hat{\nu}(x)=0 ν ^ ( x ) = 0 for x ∈ X ∖ X 0 x\in\mathcal{X}\setminus\mathcal{X}_0 x ∈ X ∖ X 0 . In particular, for every μ d a t a ∈ P ( X 0 ) \mu_{\mathrm{data}}\in\mathcal{P}(\mathcal{X}_0) μ data ∈ P ( X 0 ) ,
KL ( μ d a t a ∣ ν ^ ) = KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) . \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})=\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)}). KL ( μ data ∣ ν ^ ) = KL ( μ data ∣ μ ^ 0 ( γ ) ) .
Putting together the lemmas above, we obtain the following result.
Theorem 1. Let γ \gamma γ be a measurable map from X 0 n \mathcal{X}_0^n X 0 n to [ 1 , min { n , K d } ] [1,\min\{n,K^d\}] [ 1 , min { n , K d }] , and denote by k e f f k_{\mathrm{eff}} k eff , L γ L_\gamma L γ the quantities k e f f ( μ d a t a , n ) k_{\mathrm{eff}}(\mu_{\mathrm{data}},n) k eff ( μ data , n ) and log e K d γ \log\frac{eK^d}{\gamma} log γ e K d , respectively. Then there exists a universal constant C C C such that the following hold:
If n ≥ 8 n\geq8 n ≥ 8 , then for every deterministic γ 0 ∈ [ 1 , min { n , K d } ] \gamma_0\in[1,\min\{n,K^d\}] γ 0 ∈ [ 1 , min { n , K d }] ,
E S KL ( μ d a t a ∣ ν ^ ) ≤ C k e f f + E S [ γ ] + k e f f ∘ ( μ d a t a , n / 8 ) L γ 0 n + log ( γ 0 ) P S ( γ < γ 0 ) . (19) \mathbb{E}_S\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})\leq C\frac{k_{\mathrm{eff}}+\mathbb{E}_S[\gamma]+k_{\mathrm{eff}}^{\circ}(\mu_{\mathrm{data}},n/8)L_{\gamma_0}}{n}+\log(\gamma_0)\mathbb{P}_S(\gamma<\gamma_0). \tag*{(19)} E S KL ( μ data ∣ ν ^ ) ≤ C n k eff + E S [ γ ] + k eff ∘ ( μ data , n /8 ) L γ 0 + log ( γ 0 ) P S ( γ < γ 0 ) . (19)
If n ≥ 13 n \ge13 n ≥ 13 , K d ≥ 3 K^d \ge3 K d ≥ 3 and δ ∈ ( e − n / 6 , e − 2 ) \delta\in(e^{-n/6},e^{-2}) δ ∈ ( e − n /6 , e − 2 ) , there is an event A A A with P S ( A ) ≥ 1 − 12 δ \mathbb{P}_{S}(A) \ge1 - 12\delta P S ( A ) ≥ 1 − 12 δ on which, simultaneously for every γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] ,
KL ( μ d a t a ∣ ν ^ ) ≤ C k e f f o + γ + k e f f o ( μ d a t a , n 112 ) L γ n + ( 1 + L γ ) log 1 δ + log 1 δ log log 1 δ n . (20) \operatorname{KL}(\mu_{\mathrm{data}} \mid\hat{\nu}) \le C \frac{k_{\mathrm{eff}}^{o}+\gamma+k_{\mathrm{eff}}^{o}\left(\mu_{\mathrm{data}},\frac{n}{112}\right)L_{\gamma}}{n}+\frac{(1+L_{\gamma})\log\frac{1}{\delta}+\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}. \tag*{(20)} KL ( μ data ∣ ν ^ ) ≤ C n k eff o + γ + k eff o ( μ data , 112 n ) L γ + n ( 1 + L γ ) log δ 1 + log δ 1 log log δ 1 . (20)
The theorem above provides upper bounds of the error between μ d a t a \mu_{\mathrm{data}} μ data and the limit of the sampling process (6). We highlight that this limit is not a mere theoretical object, but is the terminal law of an implementable algorithm based on the Gillespie method [8 ] .
Sparse setting and minimax bounds
We now focus on the motivating setting where μ d a t a \mu_{\mathrm{data}} μ data is sparse, i.e. μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}_{l}(\mathcal{X}_{0}) μ data ∈ P l ( X 0 ) . We start by noticing that k e f f o ( μ d a t a , n ) , k e f f ( μ d a t a , n ) ≤ l k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n), k_{\mathrm{eff}}(\mu_{\mathrm{data}},n) \le l k eff o ( μ data , n ) , k eff ( μ data , n ) ≤ l for every n n n , and so, under no additional assumptions on γ \gamma γ , Theorem 1 produces the following corollary.
Corollary 1 (Upper bounds in the sparse setting). Let us assume the hypothesis of Lemma 4. Moreover, let us consider the setting of Lemma 2 with μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}_{l}(\mathcal{X}_{0}) μ data ∈ P l ( X 0 ) . Then, the bound becomes
E S KL ( μ d a t a ∣ ν ^ ) ≤ C l + E [ γ ] + l L γ 0 n + log ( γ 0 ) P ( γ < γ 0 ) . (21) \mathbb{E}_{S}\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})\le C\frac{l+\mathbb{E}[\gamma]+lL_{\gamma_{0}}}{n}+\log(\gamma_{0})\mathbb{P}(\gamma<\gamma_{0}). \tag*{(21)} E S KL ( μ data ∣ ν ^ ) ≤ C n l + E [ γ ] + l L γ 0 + log ( γ 0 ) P ( γ < γ 0 ) . (21) Similarly, in the setting of Lemma 3, with μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}_{l}(\mathcal{X}_{0}) μ data ∈ P l ( X 0 ) the bound becomes
KL ( μ d a t a ∣ ν ^ ) ≤ C l + γ + l L γ + ( 1 + L γ ) log ( 1 / δ ) + log ( 1 / δ ) log log ( 1 / δ ) n . (22) \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})\le C\frac{l+\gamma+lL_{\gamma}+(1+L_{\gamma})\log(1/\delta)+\log(1/\delta)\log\log(1/\delta)}{n}. \tag*{(22)} KL ( μ data ∣ ν ^ ) ≤ C n l + γ + l L γ + ( 1 + L γ ) log ( 1/ δ ) + log ( 1/ δ ) log log ( 1/ δ ) . (22)
For deterministic γ \gamma γ , Corollary 1 produces a bound with rate 1 n ( l log e K d γ + γ ) \frac{1}{n}(l\log\frac{eK^{d}}{\gamma}+\gamma) n 1 ( l log γ e K d + γ ) . Thus, even with the generic choice of γ = 1 \gamma=1 γ = 1 , we obtain O ( l d log ( K ) n ) O(\frac{ld\log(K)}{n}) O ( n l d l o g ( K ) ) which no longer necessarily scales exponentially with dimension. However, the rates are still sub-optimal when l l l is large, and to achieve minimax optimal rates of O ( l log ( e K d / l ) n ) O(\frac{l\log(eK^{d}/l)}{n}) O ( n l l o g ( e K d / l ) ) , we effectively require that γ ∼ l \gamma\sim l γ ∼ l . In the following corollary, we show that it is in fact sufficient for γ \gamma γ to be concentrated around l l l to obtain such rates. Throughout, we require that n , K d ≥ 110 n,K^{d}\ge110 n , K d ≥ 110 and 2 ≤ l ≤ min { n , ⌊ K d / 55 ⌋ } 2\le l\le\min\{n,\lfloor K^{d}/55\rfloor\} 2 ≤ l ≤ min { n , ⌊ K d /55 ⌋} ; we write Λ l : = log ( e K d / l ) \Lambda_l:=\log(eK^{d}/l) Λ l := log ( e K d / l ) and Γ δ : = l Λ l + log ( K d ) log ( 1 / δ ) \Gamma_{\delta}:=l\Lambda_l+\log(K^{d})\log(1/\delta) Γ δ := l Λ l + log ( K d ) log ( 1/ δ ) , so that Γ 1 = l Λ l \Gamma_1=l\Lambda_l Γ 1 = l Λ l . For a measurable γ : X 0 n → [ 1 , min { n , K d } ] \gamma:\mathcal{X}_{0}^{n}\to[1,\min\{n,K^{d}\}] γ : X 0 n → [ 1 , min { n , K d }] we denote by μ ^ 0 = μ ^ ( γ ) \hat{\mu}_{0}=\hat{\mu}^{(\gamma)} μ ^ 0 = μ ^ ( γ ) the estimator (1), by s ^ \hat{s} s ^ the score, and by ν ^ \hat{\nu} ν ^ the terminal law of (6) driven by s ^ \hat{s} s ^ .
Corollary 2. Fix constants 0 < c 0 ≤ 1 ≤ C 0 0<c_{0}\le1\le C_{0} 0 < c 0 ≤ 1 ≤ C 0 . There exist a universal constant c > 0 c>0 c > 0 and a constant C < ∞ C<\infty C < ∞ depending only on ( c 0 , C 0 ) (c_{0},C_{0}) ( c 0 , C 0 ) such that the following hold.
(i) If γ \gamma γ takes values in [ max { 1 , c 0 l } , min { n , K d , C 0 l Λ l } ] [\max\{1,c_{0}l\},\min\{n,K^{d},C_{0}l\Lambda_l\}] [ max { 1 , c 0 l } , min { n , K d , C 0 l Λ l }] , then for every μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}}\in\mathcal{P}_{l}(\mathcal{X}_{0}) μ data ∈ P l ( X 0 ) ,
E S KL ( μ d a t a ∣ ν ^ ) ≤ C l Λ l n . \mathbb{E}_{S}\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})\le C\frac{l\Lambda_l}{n}. E S KL ( μ data ∣ ν ^ ) ≤ C n l Λ l . (ii) Let δ ∈ ( e − min { n / 6 , K d } , e − 2 ) \delta\in(e^{-\min\{n/6,K^{d}\}},e^{-2}) δ ∈ ( e − m i n { n /6 , K d } , e − 2 ) . If γ \gamma γ takes values in [ max { 1 , c 0 l } , min { n , K d , C 0 Γ δ } ] [\max\{1,c_{0}l\},\min\{n,K^{d},C_{0}\Gamma_{\delta}\}] [ max { 1 , c 0 l } , min { n , K d , C 0 Γ δ }] , then for every μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}}\in\mathcal{P}_{l}(\mathcal{X}_{0}) μ data ∈ P l ( X 0 ) , with probability at least 1 − 12 δ 1-12\delta 1 − 12 δ ,
KL ( μ d a t a ∣ ν ^ ) ≤ C Γ δ n . \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})\le C\frac{\Gamma_{\delta}}{n}. KL ( μ data ∣ ν ^ ) ≤ C n Γ δ .
We observe that the interval above depends on the sparsity parameter l l l , which is unknown in general. We find that a suitable estimator that reaches similar rates is given by,
D n : = ∣ supp μ ^ 0 ( n ) ∣ = # { x ∈ X 0 n : N 0 ( x ) > 0 } , (23) D_n:=\left|\operatorname{supp}\hat{\mu}_{0}^{(n)}\right|=\#\{x\in\mathcal{X}_{0}^{n}:N_{0}(x)>0\}, \tag*{(23)} D n := supp μ ^ 0 ( n ) = # { x ∈ X 0 n : N 0 ( x ) > 0 } , (23)
which denotes the number of different states observed in the sample at time t = 0 t=0 t = 0 . Using it, we can define an implementable, adaptive estimator, which reaches the optimal rates described above. The result is summarized in the Appendix B.4 (Corollary 4).
Figure 1. Label-smoothed score on restricted Markov chain dataset. K L ( μ d a t a ∥ ν ^ ) \mathrm{KL}(\mu_{\mathrm{data}} \parallel\hat{\nu}) KL ( μ data ∥ ν ^ ) against γ \gamma γ , for n ∈ { 64 , 256 , 1024 } n \in\{64, 256, 1024\} n ∈ { 64 , 256 , 1024 } for different values of l l l (blue to red). Dots mark the adaptive choice γ = D n \gamma= D_n γ = D n .
Statistical rates for other diffusions
We now extend outside of the masked setting to more general diffusions. For the masked diffusion, the factorization in (11) expresses the score as a classifier for the masked token multiplied by an explicit time-dependent factor, and it is this structure that motivated our use of label smoothing. For a general generator Q 0 Q_0 Q 0 , no such factorization is available. We show, however, that the mixed score entropy loss L M \mathcal{L}^{M} L M of § 3.1 still admits an explicit minimizer, which smooths the empirical score in a manner analogous to label smoothing. We use this to extend our statistical guarantees to uniform corruption setting.
By linearity of the score entropy loss with respect to the data distribution, the mixed loss L M \mathcal{L}^{M} L M can be expressed as a score entropy loss for the measure μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) defined in (1). Thus, via the equivalence of the score entropy loss and the score matching loss, L M \mathcal{L}^{M} L M is uniquely minimized by the score,
s ^ ( x , y , t ) : = μ ^ t ( x ) μ ^ t ( y ) = P 0 , t μ ^ 0 ( γ ) ( x ) P 0 , t μ ^ 0 ( γ ) ( y ) . (24) \hat{s}(x,y,t) := \frac{\hat{\mu}_t(x)}{\hat{\mu}_t(y)} = \frac{P_{0,t}\hat{\mu}_0^{(\gamma)}(x)}{P_{0,t}\hat{\mu}_0^{(\gamma)}(y)}. \tag*{(24)} s ^ ( x , y , t ) := μ ^ t ( y ) μ ^ t ( x ) = P 0 , t μ ^ 0 ( γ ) ( y ) P 0 , t μ ^ 0 ( γ ) ( x ) . (24)
Writing μ t ( n ) : = P 0 , t μ 0 ( n ) \mu_t^{(n)} := P_{0,t}\mu_0^{(n)} μ t ( n ) := P 0 , t μ 0 ( n ) for the noised empirical measure and s ⋆ , ( n ) s^{\star,(n)} s ⋆ , ( n ) for its score, we have μ ^ t = n n + γ μ t ( n ) + γ n + γ μ t U \hat{\mu}_t = \frac{n}{n+\gamma}\mu_t^{(n)} + \frac{\gamma}{n+\gamma}\mu_t^{U} μ ^ t = n + γ n μ t ( n ) + n + γ γ μ t U , and dividing μ ^ t ( x ) \hat{\mu}_t(x) μ ^ t ( x ) by μ ^ t ( y ) \hat{\mu}_t(y) μ ^ t ( y ) gives
s ^ ( x , y , t ) = ( 1 − ε t ( y ) ) s ⋆ , ( n ) ( x , y , t ) + ε t ( y ) s U ⋆ ( x , y , t ) , ε t ( y ) : = γ μ t U ( y ) γ μ t U ( y ) + n μ t ( n ) ( y ) . (25) \hat{s}(x,y,t) = (1-\varepsilon_t(y))s^{\star,(n)}(x,y,t) + \varepsilon_t(y)s_U^{\star}(x,y,t), \qquad\varepsilon_t(y) := \frac{\gamma\mu_t^{U}(y)}{\gamma\mu_t^{U}(y)+n\mu_t^{(n)}(y)}. \tag*{(25)} s ^ ( x , y , t ) = ( 1 − ε t ( y )) s ⋆ , ( n ) ( x , y , t ) + ε t ( y ) s U ⋆ ( x , y , t ) , ε t ( y ) := γ μ t U ( y ) + n μ t ( n ) ( y ) γ μ t U ( y ) . (25)
In the masked case, (25) recovers exactly the label smoothing of § 3.1 .
Uniform diffusion
We now consider the case of the uniform diffusion, for which we can obtain a neat expression of the mixed score-entropy loss as well as statistical rates for the limiting terminal distribution. In this case, μ t U = Unif ( X 0 ) \mu_t^{U} = \operatorname{Unif}(\mathcal{X}_0) μ t U = Unif ( X 0 ) for every t t t , and so s U ⋆ ≡ 1 s_U^{\star} \equiv1 s U ⋆ ≡ 1 . Thus, the uniform score entropy loss takes the simple form,
L t U ( s ) = 1 K d ∑ y ∈ X 0 ∑ x ≠ y Q t ( y , x ) ( s ( x , y , t ) − log s ( x , y , t ) − 1 ) . \mathcal{L}_t^{U}(s) = \frac{1}{K^d}\sum_{y\in\mathcal{X}_0}\sum_{x\ne y}Q_t(y,x)\left(s(x,y,t)-\log s(x,y,t)-1\right). L t U ( s ) = K d 1 y ∈ X 0 ∑ x = y ∑ Q t ( y , x ) ( s ( x , y , t ) − log s ( x , y , t ) − 1 ) .
Furthermore, ε t ( y ) = γ / ( γ + n K d μ t ( γ ) ( y ) ) \varepsilon_t(y) = \gamma/(\gamma+ nK^d\mu_t^{(\gamma)}(y)) ε t ( y ) = γ / ( γ + n K d μ t ( γ ) ( y )) and the measure μ t ( γ ) ( y ) \mu_t^{(\gamma)}(y) μ t ( γ ) ( y ) has a closed-form expression:
μ t ( γ ) ( y ) = K − d n ∑ k = 1 n ( 1 + ( K − 1 ) α t ) d − H k ( y ) ( 1 − α t ) H k ( y ) = : w t ( y ) , \mu_t^{(\gamma)}(y) = \frac{K^{-d}}{n} \sum_{k=1}^{n} \left(1 + (K-1)\alpha_t\right)^{d-H_k(y)}(1-\alpha_t)^{H_k(y)} =: w_t(y), μ t ( γ ) ( y ) = n K − d k = 1 ∑ n ( 1 + ( K − 1 ) α t ) d − H k ( y ) ( 1 − α t ) H k ( y ) =: w t ( y ) ,
where H k ( y ) : = # { j ∈ [ d ] : y j ≠ X 0 , j ( k ) } H_k(y) := \#\{j \in[d] : y_j \ne X_{0,j}^{(k)}\} H k ( y ) := # { j ∈ [ d ] : y j = X 0 , j ( k ) } is the Hamming distance between y y y and the k k k -th sample.
Turning to statistical rates, Lemmas 2 and 3 apply without modification, since they concern only the estimator μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) . The difference lies in the sampling step. For masked diffusion, the event that all tokens are masked at time T T T is independent of X 0 X_0 X 0 , so that initializing the sampler at the fully masked state recovers μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) exactly for every T T T (Lemma 4). Uniform diffusion admits no such state, and initializing the sampler at Unif ( X 0 ) ≠ μ ^ T \operatorname{Unif}(\mathcal{X}_0) \ne\hat{\mu}_T Unif ( X 0 ) = μ ^ T incurs an additional error, which is controlled in the following lemma.
Lemma 5 (Relative entropy of the sampler output). Let γ > 0 \gamma> 0 γ > 0 , let μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) be as in (1) and s ^ \hat{s} s ^ as in (24), and assume σ ˉ t > 0 \bar{\sigma}_t > 0 σ ˉ t > 0 for every t ∈ ( 0 , T ] t \in(0,T] t ∈ ( 0 , T ] . Let ( ν u ) u (\nu_u)_u ( ν u ) u be the solution of (6) with score s ^ \hat{s} s ^ and ν ^ : = lim u ↑ T ν u \hat{\nu} := \lim_{u \uparrow T} \nu_u ν ^ := lim u ↑ T ν u its terminal law. If σ ˉ T ≥ log ( d K n ) \bar{\sigma}_T \ge\log(dKn) σ ˉ T ≥ log ( d K n ) , then for every μ d a t a ∈ P ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}(\mathcal{X}_0) μ data ∈ P ( X 0 ) , the solution exists in all [ 0 , T ] [0,T] [ 0 , T ] , with ν ^ = ν T \hat{\nu} = \nu_T ν ^ = ν T and KL ( μ d a t a ∣ ν ^ ) ≤ KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) + 1 n \operatorname{KL}(\mu_{\mathrm{data}} \mid\hat{\nu}) \le\operatorname{KL}(\mu_{\mathrm{data}} \mid\hat{\mu}_0^{(\gamma)}) + \frac{1}{n} KL ( μ data ∣ ν ^ ) ≤ KL ( μ data ∣ μ ^ 0 ( γ ) ) + n 1 .
The initialization error thus contributes an additional term of order 1 / n 1/n 1/ n . Since k e f f ≥ 1 k_{\mathrm{eff}} \ge1 k eff ≥ 1 , this term is absorbed into k e f f / n k_{\mathrm{eff}}/n k eff / n up to a universal constant. As a result, uniform diffusion attains the same bounds as masked diffusion, at the cost of a logarithmic lower bound on the time horizon that is not required in the masked case. In the following theorem, we obtain end-to-end bounds for the limiting terminal law.
Theorem 2 (Uniform diffusion). Let γ \gamma γ be a measurable map from X 0 n \mathcal{X}_0^n X 0 n to [ 1 , min { n , K d } ] [1,\min\{n,K^d\}] [ 1 , min { n , K d }] and consider the uniform diffusion with σ ˉ T ≥ log ( d K n ) \bar{\sigma}_T \ge\log(dKn) σ ˉ T ≥ log ( d K n ) and terminal law ν ^ : = lim u ↑ T ν u \hat{\nu} := \lim_{u \uparrow T} \nu_u ν ^ := lim u ↑ T ν u . Then, both statements of Theorem 1 hold for some different universal constant C C C .
In particular, under the hypotheses of the theorem above, the minimax rates obtained for the masked setting in Corollary 1 and Corollary 2 transfer to the uniform setting also.
Figure 3. Transformer model trained with regularized score-entropy loss, L M \mathcal{L}^{M} L M on the text8 12-gram target (K = 27 K = 27 K = 27 , d = 12 d = 12 d = 12 ). Training trajectories are plotted for different values of γ \gamma γ .
Experiments
We now provide some experiments that empirically evaluate our theoretical results. This also allows us to inspect the potential practical utility of two objects introduced in § 3.1 : the label-smoothed estimator, which requires no training, and the mixed loss L t M \mathcal{L}^{M}_{t} L t M , which we use to regularize a score network during training.
Exact label smoothing. We first analyze the effect of label smoothing by computing the closed form estimator ψ ^ c \hat{\psi}_{c} ψ ^ c directly from dataset counts. As targets, we take the stationary laws of sparse Markov chains on V = [ 4 ] \mathcal{V} = [4] V = [ 4 ] with d = 8 d = 8 d = 8 , so that K d = 65,536 K^{d} = 65{,}536 K d = 65 , 536 . Restricting the allowed transitions yields support sizes l l l ranging from 16 to 4096. The masked sampler returns exactly μ ^ 0 ( γ ) \hat{\mu}_{0}^{(\gamma)} μ ^ 0 ( γ ) and so KL ( μ d a t a ∣ ν ) \operatorname{KL}(\mu_{\mathrm{data}} \mid\nu) KL ( μ data ∣ ν ) can be computed in closed form. Figure 2 shows that, for every l l l and n n n , the error forms a U-shape in γ \gamma γ and that the adaptive choice of γ = D n \gamma= D_{n} γ = D n lands close to but not at its minimum, without any direct knowledge of l l l .
Figure 2. Label-smoothed score on restricted Markov chain dataset as in Figure 2 . KL ( μ d a t a ∣ ν ^ ) \operatorname{KL}(\mu_{\mathrm{data}} \mid\hat{\nu}) KL ( μ data ∣ ν ^ ) against l l l for different choices of γ \gamma γ demonstrating sparsity-adaptive behavior of small γ \gamma γ .
Learning with the mixed loss. We now inspect the utility of the mixed score-entropy loss L t M \mathcal{L}^{M}_{t} L t M for training, which can be approximated by replacing each training sequence by a uniformly random one with probability p = γ / ( n + γ ) p = \gamma/(n+\gamma) p = γ / ( n + γ ) . As a target we take the empirical 12-gram law of text8 (K = 27 K = 27 K = 27 , d = 12 d = 12 d = 12 ), drawing training and held-out sequences from disjoint halves of the corpus. At this length essentially every drawn sequence is distinct (D n / n ≥ 0.994 D_{n}/n \ge0.994 D n / n ≥ 0.994 ), so this experiment probes the practical utility of the regulariser rather than the sparsity bound, which is vacuous when k e f f = n k_{\mathrm{eff}} = n k eff = n . We anchor the grid to the data-driven value, γ ∈ { 0 , D n / 16 , D n / 4 , D n / 2 , D n } \gamma\in\{0, D_{n}/16, D_{n}/4, D_{n}/2, D_{n}\} γ ∈ { 0 , D n /16 , D n /4 , D n /2 , D n } , so that the prescription γ = D n \gamma= D_{n} γ = D n lies on the grid at every n n n , and give every arm ⌈ 6000 / ( 1 − p ) ⌉ \lceil6000/(1-p)\rceil ⌈ 6000/ ( 1 − p )⌉ iterations so that all arms see the same expected number of real training sequences.
Our results suggest that there may be some practical utility to utilizing label smoothing in the context of discrete diffusion. However, validating this will require a detailed ablation in more practical high dimensional settings, which we leave for future work.
Conclusion
In this work, we analyze the statistical efficiency of discrete diffusion models under sparsity. For the masked setting, we develop a regularized nonparametric estimator of the score function derived by treating it as a classifier and applying label smoothing. By regularizing the score in this fashion, we establish upper bounds on the KL divergence which achieve minimax optimal rates in the class of sparse distributions. We show that the same rates hold for uniform diffusion: the regularized score is again the exact score of (1), but the smoothing it induces has no interpretation as label smoothing of a classifier. Since the minimax lower bound is the same for both kernels, our results rule out a separation between masked and uniform diffusion at the level of the minimax risk over sparse distributions. Whether the gap observed in practice comes from approximation or optimization of the score, is a question we leave open. While our primary focus is providing theoretical justification for the success discrete diffusion, our work also suggests two practical methods of regularization for masked diffusions—label smoothing of the score and regularization via the uniform score-entropy loss—whose rigorous empirical evaluation we leave for future work.
Acknowledgments
U.S. is partially supported by the French government under the management of Agence Nationale de la Recherche as part of the “Investissements d’avenir” program, reference ANR-19-P3IA-0001 (PRAIRIE 3IA Institute). L.B., T.F., and U.S. are supported by the European Research Council Starting Grant DYNASTY – 101039676. A.D. is supported by the France 2030 program with the reference ANR-25-PEIA-0001 (THEOREM project). A.D. is funded by the European Union (ERC-2022-SYG-OCEAN-101071601). Views and opinions expressed are however those of the author(s) only and do not necessarily reflect those of the European Union or the European Research Council Executive Agency. Neither the European Union nor the granting authority can be held responsible for them. A.D. is supported by Paris and Agence Nationale de la Recherche (Grant 11-LABX-0047). This work received government funding administered by the National Research Agency (ANR) under the France 2030 program ”Hi! PARIS”, grant number ANR-23-IACL-0005.
Background
Background on the Process
Throughout, as in § 2 , we use the column-generator convention, which means that for x ≠ y x \ne y x = y , Q t ( x , y ) ≥ 0 Q_t(x,y) \ge0 Q t ( x , y ) ≥ 0 is the instantaneous rate of a jump from y y y to x x x , and Q t ( y , y ) = − ∑ x ≠ y Q t ( x , y ) Q_t(y,y)=-\sum_{x\ne y}Q_t(x,y) Q t ( y , y ) = − ∑ x = y Q t ( x , y ) . Also, we defined P 0 , t ( x , y ) = P ( X t = x ∣ X 0 = y ) P_{0,t}(x,y)=\mathbb{P}(X_t=x\mid X_0=y) P 0 , t ( x , y ) = P ( X t = x ∣ X 0 = y ) , so we can rewrite μ t = P 0 , t μ 0 \mu_t=P_{0,t}\mu_0 μ t = P 0 , t μ 0 . Since the infinitesimal generator can be rewritten as Q t = σ t Q 0 Q_t=\sigma_tQ_0 Q t = σ t Q 0 , with Q 0 Q_0 Q 0 a fixed conservative, the generators commute across times and
P 0 , t = exp ( ∫ 0 t Q u d u ) = e σ ˉ t Q 0 , σ ˉ t = ∫ 0 t σ u d u , (26) P_{0,t}=\exp\left(\int_0^t Q_u\,du\right)=e^{\bar{\sigma}_tQ_0},\qquad\bar{\sigma}_t=\int_0^t\sigma_u\,du, \tag*{(26)} P 0 , t = exp ( ∫ 0 t Q u d u ) = e σ ˉ t Q 0 , σ ˉ t = ∫ 0 t σ u d u , (26)
with the semigroup property P 0 , t 3 = e ( σ ˉ t 3 − σ ˉ t 2 ) Q 0 P 0 , t 2 P_{0,t_3}=e^{(\bar{\sigma}_{t_3}-\bar{\sigma}_{t_2})Q_0}P_{0,t_2} P 0 , t 3 = e ( σ ˉ t 3 − σ ˉ t 2 ) Q 0 P 0 , t 2 for t 2 ≤ t 3 t_2\le t_3 t 2 ≤ t 3 .
In both processes below, the matrix Q 0 Q_0 Q 0 acts independently on the d d d coordinates, so we can connect its sequence version Q 0 s e q Q_0^{\mathrm{seq}} Q 0 seq with the token one Q 0 t o k Q_0^{\mathrm{tok}} Q 0 tok as Q 0 s e q = ∑ i = 1 d I ⊗ ( i − 1 ) ⊗ Q 0 t o k ⊗ I ⊗ ( d − i ) Q_0^{\mathrm{seq}}=\sum_{i=1}^d I^{\otimes(i-1)}\otimes Q_0^{\mathrm{tok}}\otimes I^{\otimes(d-i)} Q 0 seq = ∑ i = 1 d I ⊗ ( i − 1 ) ⊗ Q 0 tok ⊗ I ⊗ ( d − i ) . In particular, P 0 , t s e q = ( P 0 , t t o k ) ⊗ d P_{0,t}^{\mathrm{seq}}=(P_{0,t}^{\mathrm{tok}})^{\otimes d} P 0 , t seq = ( P 0 , t tok ) ⊗ d : the kernels factorize coordinatewise, and it suffices to compute the single-token propagator. Finally, both token generators are of the form Q 0 t o k = Π − I Q_0^{\mathrm{tok}}=\Pi-I Q 0 tok = Π − I with Π \Pi Π a projection (thus it satisfies Π 2 = Π \Pi^2=\Pi Π 2 = Π ), and I K I_K I K the identity matrix K × K K\times K K × K , so
e σ ˉ t ( Π − I ) = Π + e − σ ˉ t ( I − Π ) = α t I + ( 1 − α t ) Π , α t : = e − σ ˉ t . (27) e^{\bar{\sigma}_t(\Pi-I)}=\Pi+e^{-\bar{\sigma}_t}(I-\Pi)=\alpha_t I+(1-\alpha_t)\Pi,\qquad\alpha_t:=e^{-\bar{\sigma}_t}. \tag*{(27)} e σ ˉ t ( Π − I ) = Π + e − σ ˉ t ( I − Π ) = α t I + ( 1 − α t ) Π , α t := e − σ ˉ t . (27)
Uniform process. On the token alphabet V = [ K ] \mathcal{V}=[K] V = [ K ] , take Π : = 1 K 11 T \Pi:=\frac{1}{K}\mathbf{1}\mathbf{1}^{\mathsf{T}} Π := K 1 1 1 T and Q 0 u n i f : = Π − I K Q_0^{\mathrm{unif}}:=\Pi-I_K Q 0 unif := Π − I K : every token jumps to each of the other K − 1 K-1 K − 1 values at rate 1 / K 1/K 1/ K . By (27) and tensorization,
P 0 , t u n i f ( x , x 0 ) = ∏ i = 1 d [ α t 1 { x i = x 0 , i } + 1 − α t K ] . P_{0,t}^{\mathrm{unif}}(x,x_0)=\prod_{i=1}^{d}\left[\alpha_t\mathbf{1}\{x_i=x_{0,i}\}+\frac{1-\alpha_t}{K}\right]. P 0 , t unif ( x , x 0 ) = i = 1 ∏ d [ α t 1 { x i = x 0 , i } + K 1 − α t ] .
The off-diagonal rates of Q 0 s e q Q_0^{\mathrm{seq}} Q 0 seq equal 1 / K 1/K 1/ K , so Q 0 max = 1 / K Q_0^{\max}=1/K Q 0 m a x = 1/ K , and the total exit rate of any state is d ( K − 1 ) / K ≤ d d(K-1)/K\le d d ( K − 1 ) / K ≤ d . The uniform law on V d \mathcal{V}^d V d is stationary (each column of Π − I K \Pi-I_K Π − I K sums to zero against the uniform vector).
Canonical absorbing process. On the token alphabet V ∪ { m } \mathcal{V}\cup\{\mathbf{m}\} V ∪ { m } (size K + 1 K+1 K + 1 ), take Π : = e m 1 T \Pi:=\mathbf{e}_{\mathbf{m}}\mathbf{1}^{\mathsf{T}} Π := e m 1 T and Q 0 m a s k : = Π − I K + 1 Q_0^{\mathrm{mask}}:=\Pi-I_{K+1} Q 0 mask := Π − I K + 1 : every real token jumps to m \mathbf{m} m at unit rate, and m \mathbf{m} m is absorbing. By (27) and tensorization,
P 0 , t m a s k ( x , x 0 ) = ∏ i = 1 d [ α t 1 { x i = x 0 , i } + ( 1 − α t ) 1 { x i = m } ] . P_{0,t}^{\mathrm{mask}}(x,x_0)=\prod_{i=1}^{d}\left[\alpha_t\mathbf{1}\{x_i=x_{0,i}\}+(1-\alpha_t)\mathbf{1}\{x_i=\mathbf{m}\}\right]. P 0 , t mask ( x , x 0 ) = i = 1 ∏ d [ α t 1 { x i = x 0 , i } + ( 1 − α t ) 1 { x i = m } ] .
The point mass on the fully masked sequence is stationary. The total exit rate of a state y y y equals its number of unmasked coordinates, so the total exit rate of any state is less or equal than d d d . Finally, for a state y y y with masked coordinate i ∈ M ( y ) i\in M(y) i ∈ M ( y ) and any a ∈ V a\in\mathcal{V} a ∈ V , the sequence-level rate from ( y − i , a ) (y_{-i},a) ( y − i , a ) to y y y is the token-level rate a → m a\to\mathbf{m} a → m , namely Q 0 ( y , ( y − i , a ) ) = 1 Q_0(y,(y_{-i},a))=1 Q 0 ( y , ( y − i , a )) = 1 .
Useful results
We start by giving two results that are going to be useful in the following, when we are going to need lower bounds on the class of sparse distributions.
Proposition 1 ([12 ] , Section 4.1, Proposition 1). Let n n n be the number of samples ( X ( 1 ) , … , X ( n ) ) (X^{(1)},\ldots,X^{(n)}) ( X ( 1 ) , … , X ( n ) ) , and n , ∣ X ∣ ≥ 2 n,|\mathcal{X}|\ge2 n , ∣ X ∣ ≥ 2 . Let us assume P ∈ P l ( X ) P\in\mathcal{P}_l(\mathcal{X}) P ∈ P l ( X ) . For any 1 ≤ l ≤ min ( n , ∣ X ∣ / 55 ) 1\le l\le\min(n,|\mathcal{X}|/55) 1 ≤ l ≤ min ( n , ∣ X ∣/55 ) and
any estimator P ^ n = Φ ( X ( 1 ) , … , X ( n ) ) \widehat{P}_n = \Phi(X^{(1)}, \ldots, X^{(n)}) P n = Φ ( X ( 1 ) , … , X ( n ) ) , where Φ \Phi Φ is an estimator map Φ : [ ∣ X ∣ ] n → P ( X ) \Phi: [|\mathcal{X}|]^n \to\mathcal{P}(\mathcal{X}) Φ : [ ∣ X ∣ ] n → P ( X ) , there exists a distribution P ∈ P l P \in\mathcal{P}_l P ∈ P l such that
P P ( KL ( P ∣ P ^ n ) ≥ l log ( e ∣ X ∣ / l ) 300 n ) ≥ 1 − 3 exp ( − l 35 ) . (28) \mathbb{P}_P\left(\operatorname{KL}(P \mid\widehat{P}_n) \geq\frac{l \log(e|\mathcal{X}|/l)}{300n}\right) \geq1 - 3\exp\left(-\frac{l}{35}\right). \tag*{(28)} P P ( KL ( P ∣ P n ) ≥ 300 n l log ( e ∣ X ∣/ l ) ) ≥ 1 − 3 exp ( − 35 l ) . (28)
Corollary 3 ([12 ] , Section 4.1, Corollary 1). Let us assume P ∈ P l ( X ) P \in\mathcal{P}_l(\mathcal{X}) P ∈ P l ( X ) . Let n n n be the number of samples ( X ( 1 ) , … , X ( n ) ) (X^{(1)}, \ldots, X^{(n)}) ( X ( 1 ) , … , X ( n ) ) , and n , ∣ X ∣ ≥ 110 n, |\mathcal{X}| \geq110 n , ∣ X ∣ ≥ 110 , l ∈ { 2 , … , min ( n , ∣ X ∣ / 55 ) } l \in\{2, \ldots, \min(n, |\mathcal{X}|/55)\} l ∈ { 2 , … , min ( n , ∣ X ∣/55 )} and δ ∈ ( e − n , e − 2 ) \delta\in(e^{-n}, e^{-2}) δ ∈ ( e − n , e − 2 ) . For any estimator confidence-dependent Φ = Φ n , δ : [ ∣ X ∣ ] n → P ( X ) \Phi= \Phi_{n,\delta} : [|\mathcal{X}|]^n \to\mathcal{P}(\mathcal{X}) Φ = Φ n , δ : [ ∣ X ∣ ] n → P ( X ) , there exists a distribution P ∈ P l ( X ) P \in\mathcal{P}_l(\mathcal{X}) P ∈ P l ( X ) such that, letting P ^ n = Φ ( X 1 , … , X n ) \widehat{P}_n = \Phi(X_1, \ldots, X_n) P n = Φ ( X 1 , … , X n ) , we have
P P ( KL ( P ∣ P ^ n ) ≥ l log ( e ∣ X ∣ / l ) + log ( ∣ X ∣ ) log ( 1 / δ ) 320 n ) ≥ δ . (29) \mathbb{P}_P\left(\operatorname{KL}(P \mid\widehat{P}_n) \geq\frac{l \log(e|\mathcal{X}|/l) + \log(|\mathcal{X}|)\log(1/\delta)}{320n}\right) \geq\delta. \tag*{(29)} P P ( KL ( P ∣ P n ) ≥ 320 n l log ( e ∣ X ∣/ l ) + log ( ∣ X ∣ ) log ( 1/ δ ) ) ≥ δ . (29)
We list here other results that are going to be useful. In the following for a ≥ 0 a \geq0 a ≥ 0 and b > 0 b > 0 b > 0 we set, with the convention 0 log 0 : = 0 0 \log0 := 0 0 log 0 := 0 ,
D ( a , b ) : = a log a b − a + b , D(a,b) := a \log\frac{a}{b} - a + b, D ( a , b ) := a log b a − a + b ,
so that D ( 0 , b ) = b D(0,b) = b D ( 0 , b ) = b . Using ϕ \phi ϕ , one has D ( a , b ) = ϕ ( a ) − ϕ ( b ) − ϕ ′ ( b ) ( a − b ) D(a,b) = \phi(a) - \phi(b) - \phi'(b)(a-b) D ( a , b ) = ϕ ( a ) − ϕ ( b ) − ϕ ′ ( b ) ( a − b ) , i.e. D D D is the Bregman divergence of ϕ \phi ϕ . In particular D ( a , b ) = b h ( a / b ) D(a,b) = b h(a/b) D ( a , b ) = bh ( a / b ) with h ( u ) = u log u − u + 1 ≥ 0 h(u) = u \log u - u + 1 \geq0 h ( u ) = u log u − u + 1 ≥ 0 , hence D ≥ 0 D \geq0 D ≥ 0 with equality iff a = b a = b a = b ; additionally, D D D is jointly convex and positively homogeneous, D ( c a , c b ) = c D ( a , b ) D(ca, cb) = cD(a,b) D ( c a , c b ) = cD ( a , b ) for c ≥ 0 c \geq0 c ≥ 0 .
Lemma 6 (Relative entropy along two Markov flows). Let τ > 0 \tau> 0 τ > 0 and let u ↦ A u , B u u \mapsto A_u, B_u u ↦ A u , B u measurable maps from [ 0 , τ ] [0,\tau] [ 0 , τ ] to R ∣ X ∣ × ∣ X ∣ \mathbb{R}^{|\mathcal{X}|\times|\mathcal{X}|} R ∣ X ∣ × ∣ X ∣ . Called M u : = max x , y ( ∣ A u ( x , y ) ∣ + ∣ B u ( x , y ) ∣ ) M_u := \max_{x,y}(|A_u(x,y)| + |B_u(x,y)|) M u := max x , y ( ∣ A u ( x , y ) ∣ + ∣ B u ( x , y ) ∣ ) , we assume ∫ 0 τ M u d u < ∞ \int_0^\tau M_u\,du < \infty ∫ 0 τ M u d u < ∞ . Moreover, we take A u A_u A u and B u B_u B u as conservative generator in the column convention of § 2 . Now, let ( p u ) u ∈ [ 0 , τ ] , ( q u ) u ∈ [ 0 , τ ] (p_u)_{u\in[0,\tau]}, (q_u)_{u\in[0,\tau]} ( p u ) u ∈ [ 0 , τ ] , ( q u ) u ∈ [ 0 , τ ] be the absolutely continuous solutions of ∂ u p u = A u p u \partial_u p_u = A_u p_u ∂ u p u = A u p u , ∂ u q u = B u q u \partial_u q_u = B_u q_u ∂ u q u = B u q u with p 0 , q 0 ∈ P ( X ) p_0, q_0 \in\mathcal{P}(\mathcal{X}) p 0 , q 0 ∈ P ( X ) and q 0 > 0 q_0 > 0 q 0 > 0 on X \mathcal{X} X , and assume that the support S S S of p u p_u p u does not depend on u ∈ [ 0 , τ ] u \in[0,\tau] u ∈ [ 0 , τ ] . Then, q u > 0 q_u > 0 q u > 0 on X \mathcal{X} X for every u u u , the map u ↦ KL ( p u ∣ q u ) u \mapsto\operatorname{KL}(p_u|q_u) u ↦ KL ( p u ∣ q u ) is absolutely continuous on [ 0 , τ ] [0,\tau] [ 0 , τ ] , and, writing r u : = p u / q u r_u := p_u/q_u r u := p u / q u , for a.e. u u u
d d u KL ( p u ∣ q u ) = ∑ y ∈ X ∑ x ≠ y [ A u ( x , y ) p u ( y ) log r u ( x ) r u ( y ) − B u ( x , y ) q u ( y ) ( r u ( x ) − r u ( y ) ) ] . (30) \frac{d}{du}\operatorname{KL}(p_u|q_u) = \sum_{y\in\mathcal{X}}\sum_{x\ne y}\left[A_u(x,y)p_u(y)\log\frac{r_u(x)}{r_u(y)} - B_u(x,y)q_u(y)\bigl(r_u(x)-r_u(y)\bigr)\right]. \tag*{(30)} d u d KL ( p u ∣ q u ) = y ∈ X ∑ x = y ∑ [ A u ( x , y ) p u ( y ) log r u ( y ) r u ( x ) − B u ( x , y ) q u ( y ) ( r u ( x ) − r u ( y ) ) ] . (30) where above if a term satisfies A u ( x , y ) p u ( y ) = 0 A_u(x,y)p_u(y) = 0 A u ( x , y ) p u ( y ) = 0 , then the whole term is substitute by 0 (for a.e. u u u this covers every pair with x ∉ S x \notin S x ∈ / S or y ∉ S y \notin S y ∈ / S ). In particular, with D ( a , 0 ) : = + ∞ D(a,0) := +\infty D ( a , 0 ) := + ∞ for a > 0 a > 0 a > 0 and D ( 0 , 0 ) : = 0 D(0,0) := 0 D ( 0 , 0 ) := 0 , for a.e. u u u
d d u KL ( p u ∣ q u ) ≤ ∑ y ∈ X p u ( y ) ∑ x ≠ y D ( A u ( x , y ) , B u ( x , y ) ) . (31) \frac{d}{du}\operatorname{KL}(p_u|q_u) \leq\sum_{y\in\mathcal{X}}p_u(y)\sum_{x\ne y}D(A_u(x,y),B_u(x,y)). \tag*{(31)} d u d KL ( p u ∣ q u ) ≤ y ∈ X ∑ p u ( y ) x = y ∑ D ( A u ( x , y ) , B u ( x , y )) . (31)
Proof. We start by showing the positivity of q q q . Since solutions of Kolmogorov equations with bounded conservative generators stay in P ( X ) \mathcal{P}(\mathcal{X}) P ( X ) , we deduce immediately that q u ≥ 0 q_u \geq0 q u ≥ 0 and, by the column convention, ∂ u q u ( x ) ≥ − ( ∣ X ∣ − 1 ) M u q u ( x ) \partial_u q_u(x) \geq-(|\mathcal{X}|-1)M_u q_u(x) ∂ u q u ( x ) ≥ − ( ∣ X ∣ − 1 ) M u q u ( x ) ; using Grönwall’s lemma for integrable coefficients, we get q u ( x ) ≥ q 0 ( x ) exp ( − ( ∣ X ∣ − 1 ) ∫ 0 u M z d z ) > 0 q_u(x) \geq q_0(x)\exp\left(-(|\mathcal{X}|-1)\int_0^u M_z\,dz\right) > 0 q u ( x ) ≥ q 0 ( x ) exp ( − ( ∣ X ∣ − 1 ) ∫ 0 u M z d z ) > 0 .
We focus now on the absolute continuity. On the support S = supp ( p u ) S = \operatorname{supp}(p_u) S = supp ( p u ) the functions u ↦ p u ( x ) u \mapsto p_u(x) u ↦ p u ( x ) are continuous and positive, hence bounded away from 0 on [ 0 , τ ] [0,\tau] [ 0 , τ ] , and similarly for q u ( x ) q_u(x) q u ( x ) . Thus
KL ( p u ∣ q u ) = ∑ x ∈ S [ p u ( x ) log p u ( x ) − p u ( x ) log q u ( x ) ] (32) \operatorname{KL}(p_u|q_u) = \sum_{x\in S}\left[p_u(x)\log p_u(x)-p_u(x)\log q_u(x)\right] \tag*{(32)} KL ( p u ∣ q u ) = x ∈ S ∑ [ p u ( x ) log p u ( x ) − p u ( x ) log q u ( x ) ] (32)
is a finite sum of products of absolutely continuous functions with smooth functions of absolutely continuous functions taking values in compact subsets of ( 0 , ∞ ) (0,\infty) ( 0 , ∞ ) ; therefore, it is absolutely continuous and can be differentiated term by term for a.e. u u u .
For a.e. u u u and every x ∉ S x \notin S x ∈ / S ,
0 = ∂ u p u ( x ) = ∑ y ≠ x A u ( x , y ) p u ( y ) 0 = \partial_u p_u(x) = \sum_{y\ne x} A_u(x,y)p_u(y) 0 = ∂ u p u ( x ) = y = x ∑ A u ( x , y ) p u ( y )
is a sum of nonnegative terms, since A , p u ≥ 0 A,p_u \ge0 A , p u ≥ 0 , thus
A u ( x , y ) p u ( y ) = 0 (33) A_u(x,y)p_u(y) = 0 \tag*{(33)} A u ( x , y ) p u ( y ) = 0 (33)
whenever x ∉ S x \notin S x ∈ / S for a.e. u u u , and ∑ x ∈ S ∂ u p u ( x ) = ∂ u ∑ x ∈ S p u ( x ) = 0 \sum_{x\in S}\partial_u p_u(x) = \partial_u\sum_{x\in S}p_u(x) = 0 ∑ x ∈ S ∂ u p u ( x ) = ∂ u ∑ x ∈ S p u ( x ) = 0 . If we omit the index u u u now, and using the two facts above and r = 0 r=0 r = 0 outside of S S S ,
d d u KL ( p ∥ q ) = ∑ x ∈ S ∂ u p ( x ) log r ( x ) − ∑ x ∈ S r ( x ) ∂ u q ( x ) . (34) \frac{d}{du}\operatorname{KL}(p\mathbin\Vert q) = \sum_{x\in S}\partial_u p(x)\log r(x) - \sum_{x\in S}r(x)\partial_u q(x). \tag*{(34)} d u d KL ( p ∥ q ) = x ∈ S ∑ ∂ u p ( x ) log r ( x ) − x ∈ S ∑ r ( x ) ∂ u q ( x ) . (34)
Thanks to the column convention,
∂ u p ( x ) = ∑ y ≠ x A ( x , y ) p ( y ) − p ( x ) ∑ y ≠ x A ( y , x ) . \partial_u p(x) = \sum_{y\ne x}A(x,y)p(y)-p(x)\sum_{y\ne x}A(y,x). ∂ u p ( x ) = y = x ∑ A ( x , y ) p ( y ) − p ( x ) y = x ∑ A ( y , x ) .
Hence, the first term in (33) reads
∑ x ∈ S ∂ p ( x ) log r ( x ) = ∑ x ∈ S ∑ y ≠ x A ( x , y ) p ( y ) log r ( x ) − ∑ x ∈ S p ( x ) ∑ y ≠ x A ( y , x ) log r ( x ) . \sum_{x\in S}\partial p(x)\log r(x)=\sum_{x\in S}\sum_{y\ne x}A(x,y)p(y)\log r(x)-\sum_{x\in S}p(x)\sum_{y\ne x}A(y,x)\log r(x). x ∈ S ∑ ∂ p ( x ) log r ( x ) = x ∈ S ∑ y = x ∑ A ( x , y ) p ( y ) log r ( x ) − x ∈ S ∑ p ( x ) y = x ∑ A ( y , x ) log r ( x ) .
In the second double sum only y ∈ S y\in S y ∈ S contribute, by (32). Exchanging the names of x x x and y y y there, and extending the first double sum to all x x x by (32) with the stated convention, we obtain ∑ y ∈ S p ( y ) ∑ x ≠ y A ( x , y ) [ log r ( x ) − log r ( y ) ] \sum_{y\in S}p(y)\sum_{x\ne y}A(x,y)[\log r(x)-\log r(y)] ∑ y ∈ S p ( y ) ∑ x = y A ( x , y ) [ log r ( x ) − log r ( y )] . Similarly, using r ( x ) = 0 r(x)=0 r ( x ) = 0 for x ∉ S x\notin S x ∈ / S and q ( y ) r ( y ) = p ( y ) q(y)r(y)=p(y) q ( y ) r ( y ) = p ( y ) , so in particular
∑ x ∈ S r ( x ) ∂ u q ( x ) = ∑ y ∑ x ≠ y B ( x , y ) q ( y ) r ( x ) − ∑ y p ( y ) ∑ x ≠ y B ( x , y ) = ∑ y ∑ x ≠ y B ( x , y ) q ( y ) ( r ( x ) − r ( y ) ) . \begin{aligned}
\sum_{x\in S}r(x)\partial_u q(x)=\sum_y\sum_{x\ne y}B(x,y)q(y)r(x)-\sum_y p(y)\sum_{x\ne y}B(x,y) \\
&=\sum_y\sum_{x\ne y}B(x,y)q(y)(r(x)-r(y)).
\end{aligned} x ∈ S ∑ r ( x ) ∂ u q ( x ) = y ∑ x = y ∑ B ( x , y ) q ( y ) r ( x ) − y ∑ p ( y ) x = y ∑ B ( x , y ) = y ∑ x = y ∑ B ( x , y ) q ( y ) ( r ( x ) − r ( y )) .
This proves (30) .
Finally, to prove the upper bound, we split the sum in (30) in y ∉ S y\notin S y ∈ / S or y ∈ S y\in S y ∈ S . If y ∉ S y\notin S y ∈ / S then p ( y ) = r ( y ) = 0 p(y)=r(y)=0 p ( y ) = r ( y ) = 0 . Then, the term inside of the double sum in (30) is equal to
− ∑ x ≠ y B ( x , y ) q ( y ) r ( x ) ≤ 0. -\sum_{x\ne y}B(x,y)q(y)r(x)\le0. − x = y ∑ B ( x , y ) q ( y ) r ( x ) ≤ 0.
On the other side, if y ∈ S y\in S y ∈ S , factor q ( y ) = p ( y ) r ( y ) q(y)=\frac{p(y)}{r(y)} q ( y ) = r ( y ) p ( y ) and observe that r ( x ) r ( y ) ∈ [ 0 , ∞ ) \frac{r(x)}{r(y)}\in[0,\infty) r ( y ) r ( x ) ∈ [ 0 , ∞ ) : the term inside the double sum in (30) is now
p ( y ) ∑ x ≠ y [ A log r ( x ) r ( y ) − B r ( x ) r ( y ) + B ] p(y)\sum_{x\ne y}\left[A\log\frac{r(x)}{r(y)}-B\frac{r(x)}{r(y)}+B\right] p ( y ) x = y ∑ [ A log r ( y ) r ( x ) − B r ( y ) r ( x ) + B ]
where, to simplify notations, we wrote A = A ( x , y ) A=A(x,y) A = A ( x , y ) , B = B ( x , y ) B=B(x,y) B = B ( x , y ) . We show now that
A log r ( x ) r ( y ) − B r ( x ) r ( y ) + B ≤ A log A B − A + B = D ( A , B ) . A\log\frac{r(x)}{r(y)}-B\frac{r(x)}{r(y)}+B\le A\log\frac{A}{B}-A+B=D(A,B). A log r ( y ) r ( x ) − B r ( y ) r ( x ) + B ≤ A log B A − A + B = D ( A , B ) .
In fact, if A , B > 0 A,B > 0 A , B > 0 and r ( x ) r ( y ) > 0 \frac{r(x)}{r(y)} > 0 r ( y ) r ( x ) > 0 the quantity above is log w ≤ w − 1 \log w \le w - 1 log w ≤ w − 1 with w = r ( x ) r ( y ) B w = \frac{r(x)}{r(y)}B w = r ( y ) r ( x ) B , multiplied by A A A ; on the other side, if A = 0 A = 0 A = 0 both sides equal B B B ; additionally, if B = 0 < A B = 0 < A B = 0 < A the right side is + ∞ +\infty + ∞ ; if r ( x ) r ( y ) = 0 < A \frac{r(x)}{r(y)} = 0 < A r ( y ) r ( x ) = 0 < A the left side is − ∞ -\infty − ∞ (a case excluded for a.e. u u u by (32) anyway). To finish, we sum everything and obtain (31) .
To finish, we prove that for both kernels, the support of the distribution doesn’t change in ( 0 , T ] (0,T] ( 0 , T ] . In particular, it is the whole space in the uniform case and the states y y y such that there exists a state x x x in the support of the initial law ρ \rho ρ such that y y y is obtained from x x x masking some coordinates.
Lemma 7 (Support of the forward marginals). For both kernels, let us take ρ ∈ P ( X 0 ) \rho\in\mathcal{P}(\mathcal{X}_0) ρ ∈ P ( X 0 ) as the initial distribution of the process ρ t = P 0 , t ρ \rho_t = P_{0,t}\rho ρ t = P 0 , t ρ . Then,
supp ( ρ t 1 ) = supp ( ρ t 2 ) ∀ t 1 , t 2 ∈ ( 0 , T ] . \operatorname{supp}(\rho_{t_1}) = \operatorname{supp}(\rho_{t_2}) \qquad\forall t_1,t_2 \in(0,T]. supp ( ρ t 1 ) = supp ( ρ t 2 ) ∀ t 1 , t 2 ∈ ( 0 , T ] . In particular, supp ( ρ t ) = X 0 \operatorname{supp}(\rho_t) = \mathcal{X}_0 supp ( ρ t ) = X 0 for all t ∈ ( 0 , T ] t \in(0,T] t ∈ ( 0 , T ] for the uniform kernel, and supp ( ρ t ) = { y ∈ X : ρ ( X A ( y ) = y A ( y ) ) > 0 } \operatorname{supp}(\rho_t) = \{y \in\mathcal{X} : \rho(X_{A(y)} = y_{A(y)}) > 0\} supp ( ρ t ) = { y ∈ X : ρ ( X A ( y ) = y A ( y ) ) > 0 } for the masked kernel and for every t ∈ ( 0 , T ] t \in(0,T] t ∈ ( 0 , T ] . Moreover, ρ t > 0 \rho_t > 0 ρ t > 0 on X \mathcal{X} X for every t ∈ ( 0 , T ] t \in(0,T] t ∈ ( 0 , T ] if ρ > 0 \rho> 0 ρ > 0 on X 0 \mathcal{X}_0 X 0 , and finally on [ T 0 , T ] [T_0,T] [ T 0 , T ] , where T 0 > 0 T_0 > 0 T 0 > 0 , the positive entries of P 0 , t P_{0,t} P 0 , t are bounded below by a positive constant.
Proof. The statement follows immediately from the explicit form of the kernels: in fact in the uniform case, for all y , x 0 y,x_0 y , x 0 ,
P 0 , t u n i f ( y , x 0 ) ≥ ( 1 − α t K ) d > 0 ; P^{\mathrm{unif}}_{0,t}(y,x_0) \ge\left(\frac{1-\alpha_t}{K}\right)^d > 0; P 0 , t unif ( y , x 0 ) ≥ ( K 1 − α t ) d > 0 ;
on the other side, in the masked case
P 0 , t m a s k ( y , x 0 ) = α t ∣ A ( y ) ∣ ( 1 − α t ) d − ∣ A ( y ) ∣ 1 { x 0 , A ( y ) = y A ( y ) } . P^{\mathrm{mask}}_{0,t}(y,x_0) = \alpha_t^{|A(y)|}(1-\alpha_t)^{d-|A(y)|}\mathbf{1}\{x_{0,A(y)} = y_{A(y)}\}. P 0 , t mask ( y , x 0 ) = α t ∣ A ( y ) ∣ ( 1 − α t ) d − ∣ A ( y ) ∣ 1 { x 0 , A ( y ) = y A ( y ) } .
We observe that above α t ∈ ( 0 , 1 ) \alpha_t \in(0,1) α t ∈ ( 0 , 1 ) for t > 0 t > 0 t > 0 and α t ≤ α T 0 \alpha_t \le\alpha_{T_0} α t ≤ α T 0 , 1 − α t ≥ 1 − α T 0 1-\alpha_t \ge1-\alpha_{T_0} 1 − α t ≥ 1 − α T 0 on [ T 0 , T ] [T_0,T] [ T 0 , T ] . This concludes.
Proofs of Section 3
Proofs of Section 3.1
Proof of Lemma 1. For B ⊆ [ d ] B \subseteq[d] B ⊆ [ d ] and w ∈ V B w \in\mathcal{V}^B w ∈ V B let us call n B ( w ) n_B(w) n B ( w ) the number of samples that are equal to w w w in the positions B B B , i.e.
n B ( w ) : = # { k ≤ n : X 0 , B ( k ) = w } . n_B(w) := \#\{k \le n : X^{(k)}_{0,B} = w\}. n B ( w ) := # { k ≤ n : X 0 , B ( k ) = w } .
Thus, given a context c = ( A , v , i ) c = (A,v,i) c = ( A , v , i ) , we use the notation n c n_c n c to denote n A ( v ) n_A(v) n A ( v ) . We notice that it only depends on ( A , v ) (A,v) ( A , v ) . We can then rewrite
ψ c ( n ) ( a ) = n A ∪ { i } ( v , a ) n A ( v ) \psi_c^{(n)}(a) = \frac{n_{A\cup\{i\}}(v,a)}{n_A(v)} ψ c ( n ) ( a ) = n A ( v ) n A ∪ { i } ( v , a )
when n c > 0 n_c > 0 n c > 0 . Since, by assumption, there exists b i ∈ V b_i \in\mathcal{V} b i ∈ V such that μ d a t a ( X i = b ) = 0 \mu_{\mathrm{data}}(X_i = b) = 0 μ data ( X i = b ) = 0 , n A ∪ { i } ( v , b i ) = 0 n_{A\cup\{i\}}(v,b_i) = 0 n A ∪ { i } ( v , b i ) = 0 for all A , v A,v A , v and i ∉ A i \notin A i ∈ / A . It follows that
ψ ^ c ( b i ) = ε c K for every context c = ( A , v , i ) , (35) \widehat{\psi}_c(b_i) = \frac{\varepsilon_c}{K} \qquad\text{for every context } c = (A,v,i), \tag*{(35)} ψ c ( b i ) = K ε c for every context c = ( A , v , i ) , (35)
since ψ c ( n ) ( b i ) = 0 \psi_c^{(n)}(b_i) = 0 ψ c ( n ) ( b i ) = 0 if n c > 0 n_c > 0 n c > 0 , while ψ ^ c = Unif ( V ) \widehat{\psi}_c = \operatorname{Unif}(\mathcal{V}) ψ c = Unif ( V ) and ε c = 1 \varepsilon_c = 1 ε c = 1 if n c = 0 n_c = 0 n c = 0 . Let μ ˉ ∈ P ( X 0 ) \bar{\mu} \in\mathcal{P}(\mathcal{X}_0) μ ˉ ∈ P ( X 0 ) with μ ˉ > 0 \bar{\mu} > 0 μ ˉ > 0 . Thanks to Proposition 2 applied to ρ = μ ˉ \rho= \bar{\mu} ρ = μ ˉ , for t ∈ ( 0 , T ] t \in(0,T] t ∈ ( 0 , T ] , y ∈ X y \in\mathcal{X} y ∈ X , i ∈ M ( y ) i \in M(y) i ∈ M ( y ) , A = A ( y ) A = A(y) A = A ( y ) and x = ( y − i , x i ) x = (y_{-i},x_i) x = ( y − i , x i ) ,
s μ ˉ ( x , y , t ) = κ t μ ˉ ( X i = x i ∣ X A = y A ) . s_{\bar{\mu}}(x,y,t)=\kappa_t\bar{\mu}(X_i=x_i\mid X_A=y_A). s μ ˉ ( x , y , t ) = κ t μ ˉ ( X i = x i ∣ X A = y A ) .
Notice that these are exactly the pairs ( x , y ) (x,y) ( x , y ) with Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 . Hence s = κ t ψ ^ c ( y , i ) ( x i ) s=\kappa_t\hat{\psi}_{c(y,i)}(x_i) s = κ t ψ ^ c ( y , i ) ( x i ) is proper if and only if there is μ ˉ > 0 \bar{\mu}>0 μ ˉ > 0 on X 0 \mathcal{X}_0 X 0 with
μ ˉ ( X i = a ∣ X A = v ) = ψ ^ c ( a ) for all c = ( A , v , i ) , a ∈ V . (36) \bar{\mu}(X_i=a\mid X_A=v)=\hat{\psi}_c(a)\qquad\text{for all }c=(A,v,i),\ a\in\mathcal{V}. \tag*{(36)} μ ˉ ( X i = a ∣ X A = v ) = ψ ^ c ( a ) for all c = ( A , v , i ) , a ∈ V . (36)
Let us observe that such a μ ˉ \bar{\mu} μ ˉ is unique, since, by the chain rule, μ ˉ ( x ) = ∏ j = 1 d ψ ^ ( [ j − 1 ] , x < j , j ) ( x j ) \bar{\mu}(x)=\prod_{j=1}^{d}\hat{\psi}_{([j-1],x_{<j},j)}(x_j) μ ˉ ( x ) = ∏ j = 1 d ψ ^ ([ j − 1 ] , x < j , j ) ( x j ) .
We prove now the if part in the statement. Let γ ∈ ( 0 , ∞ ) \gamma\in(0,\infty) γ ∈ ( 0 , ∞ ) and μ ˉ : = μ ^ 0 \bar{\mu}:=\hat{\mu}_0 μ ˉ := μ ^ 0 , i.e.
μ ˉ ( x ) = n [ d ] ( x ) + γ K − d n + γ > 0. \bar{\mu}(x)=\frac{n_{[d]}(x)+\gamma K^{-d}}{n+\gamma}>0. μ ˉ ( x ) = n + γ n [ d ] ( x ) + γ K − d > 0.
We will often omit γ \gamma γ in the following, since it is fixed. Summing over the K d − ∣ A ∣ K^{d-|A|} K d − ∣ A ∣ sequences x x x with x A = v x_A=v x A = v we get
μ ˉ ( X A = v ) = n A ( v ) + γ K − ∣ A ∣ n + γ , \bar{\mu}(X_A=v)=\frac{n_A(v)+\gamma K^{-|A|}}{n+\gamma}, μ ˉ ( X A = v ) = n + γ n A ( v ) + γ K − ∣ A ∣ ,
and in a similar way
μ ˉ ( X A = v , X i = a ) = n A ∪ { i } ( v , a ) + γ K − ∣ A ∣ − 1 n + γ . \bar{\mu}(X_A=v,X_i=a)=\frac{n_{A\cup\{i\}}(v,a)+\gamma K^{-|A|-1}}{n+\gamma}. μ ˉ ( X A = v , X i = a ) = n + γ n A ∪ { i } ( v , a ) + γ K − ∣ A ∣ − 1 .
Dividing,
μ ˉ ( X i = a ∣ X A = v ) = n A ∪ { i } ( v , a ) + γ K − ∣ A ∣ − 1 n A ( v ) + γ K − ∣ A ∣ = ( 1 − ε c ) ψ c ( n ) ( a ) + ε c K \bar{\mu}(X_i=a\mid X_A=v)=\frac{n_{A\cup\{i\}}(v,a)+\gamma K^{-|A|-1}}{n_A(v)+\gamma K^{-|A|}}=(1-\varepsilon_c)\psi_c^{(n)}(a)+\frac{\varepsilon_c}{K} μ ˉ ( X i = a ∣ X A = v ) = n A ( v ) + γ K − ∣ A ∣ n A ∪ { i } ( v , a ) + γ K − ∣ A ∣ − 1 = ( 1 − ε c ) ψ c ( n ) ( a ) + K ε c
with ε c \varepsilon_c ε c as in (14) (note that when n c = 0 n_c=0 n c = 0 both sides equal 1 K \frac{1}{K} K 1 ). Thus (35) holds, s = s μ ˉ s=s_{\bar{\mu}} s = s μ ˉ is proper and μ s = μ ^ 0 \mu_s=\hat{\mu}_0 μ s = μ ^ 0 . If γ = ∞ \gamma=\infty γ = ∞ , ψ ^ c = Unif ( V ) \hat{\psi}_c=\operatorname{Unif}(\mathcal{V}) ψ ^ c = Unif ( V ) for every c c c , which are the conditionals of Unif ( X 0 ) \operatorname{Unif}(\mathcal{X}_0) Unif ( X 0 ) .
We work now on the only if part. To start, let μ ˉ > 0 \bar{\mu}>0 μ ˉ > 0 satisfy (35). By (34)–(35) and positivity of μ ˉ \bar{\mu} μ ˉ ,
ε c = K μ ˉ ( X A = v , X i = b i ) μ ˉ ( X A = v ) > 0 for every c = ( A , v , i ) . (37) \varepsilon_c=K\frac{\bar{\mu}(X_A=v,X_i=b_i)}{\bar{\mu}(X_A=v)}>0\qquad\text{for every }c=(A,v,i). \tag*{(37)} ε c = K μ ˉ ( X A = v ) μ ˉ ( X A = v , X i = b i ) > 0 for every c = ( A , v , i ) . (37)
We take now A ⊆ [ d ] A\subseteq[d] A ⊆ [ d ] with ∣ A ∣ ≤ d − 2 |A|\le d-2 ∣ A ∣ ≤ d − 2 , v ∈ V A v\in\mathcal{V}^A v ∈ V A , i ≠ j i\ne j i = j in [ d ] ∖ A [d]\setminus A [ d ] ∖ A and finally a , a ′ ∈ V a,a'\in\mathcal{V} a , a ′ ∈ V . Computing μ ˉ ( X A = v , X i = a , X j = a ′ ) \bar{\mu}(X_A=v,X_i=a,X_j=a') μ ˉ ( X A = v , X i = a , X j = a ′ ) in the two possible orders and dividing by μ ˉ ( X A = v ) > 0 \bar{\mu}(X_A=v)>0 μ ˉ ( X A = v ) > 0 ,
ψ ^ ( A , v , i ) ( a ) ψ ^ ( A ∪ { i } , ( v , a ) , j ) ( a ′ ) = ψ ^ ( A , v , j ) ( a ′ ) ψ ^ ( A ∪ { j } , ( v , a ′ ) , i ) ( a ) . (38) \hat{\psi}_{(A,v,i)}(a)\hat{\psi}_{(A\cup\{i\},(v,a),j)}(a')=\hat{\psi}_{(A,v,j)}(a')\hat{\psi}_{(A\cup\{j\},(v,a'),i)}(a). \tag*{(38)} ψ ^ ( A , v , i ) ( a ) ψ ^ ( A ∪ { i } , ( v , a ) , j ) ( a ′ ) = ψ ^ ( A , v , j ) ( a ′ ) ψ ^ ( A ∪ { j } , ( v , a ′ ) , i ) ( a ) . (38)
We prove now that ε c \varepsilon_c ε c depends only on ( A , v ) (A,v) ( A , v ) . Taken a = b i a=b_i a = b i , a ′ = b j a'=b_j a ′ = b j in (37), the contexts ( A ∪ { i } , ( v , b i ) , j ) (A\cup\{i\},(v,b_i),j) ( A ∪ { i } , ( v , b i ) , j ) and ( A ∪ { j } , ( v , b j ) , i ) (A\cup\{j\},(v,b_j),i) ( A ∪ { j } , ( v , b j ) , i ) have zero count, so by assumption their ψ ^ \hat{\psi} ψ ^ is Unif ( V ) \operatorname{Unif}(\mathcal{V}) Unif ( V ) ; then, the identity reads ε ( A , v , i ) K 2 = ε ( A , v , j ) K 2 \frac{\varepsilon_{(A,v,i)}}{K^2}=\frac{\varepsilon_{(A,v,j)}}{K^2} K 2 ε ( A , v , i ) = K 2 ε ( A , v , j ) . Hence ε ( A , v , i ) = ε ( A , v , j ) \varepsilon_{(A,v,i)}=\varepsilon_{(A,v,j)} ε ( A , v , i ) = ε ( A , v , j ) whenever ∣ A ∣ ≤ d − 2 |A|\le d-2 ∣ A ∣ ≤ d − 2 ; moreover, if ∣ A ∣ = d − 1 |A|=d-1 ∣ A ∣ = d − 1 there is a single context with first two entries ( A , v ) (A,v) ( A , v ) , so they must coincide. We write from now on then ε A , v \varepsilon_{A,v} ε A , v .
Take now a = b i a=b_i a = b i and a ′ a' a ′ arbitrary in (37). By (34), the uniqueness of ε c \varepsilon_c ε c fixed ( A , v ) (A,v) ( A , v ) and the fact that ( A ∪ { i } , ( v , b i ) , j ) (A\cup\{i\},(v,b_i),j) ( A ∪ { i } , ( v , b i ) , j ) has zero count, after multiplying by K K K , we get in the case ∣ A ∣ ≤ d − 2 |A|\le d-2 ∣ A ∣ ≤ d − 2 , j ∉ A j\notin A j ∈ / A , a ′ ∈ V a'\in\mathcal{V} a ′ ∈ V , the other is trivial as shown above,
ε A , v K = ψ ^ ( A , v , j ) ( a ′ ) ε A ∪ { j } , ( v , a ′ ) . (39) \frac{\varepsilon_{A,v}}{K}=\hat{\psi}_{(A,v,j)}(a')\varepsilon_{A\cup\{j\},(v,a')}. \tag*{(39)} K ε A , v = ψ ^ ( A , v , j ) ( a ′ ) ε A ∪ { j } , ( v , a ′ ) . (39)
For ( B , w ) (B,w) ( B , w ) with n B ( w ) > 0 n_B(w)>0 n B ( w ) > 0 and ∣ B ∣ ≤ d − 1 |B|\le d-1 ∣ B ∣ ≤ d − 1 define
g ( B , w ) : = ε B , w n B ( w ) K ∣ B ∣ 1 − ε B , w ∈ ( 0 , ∞ ] . g(B,w):=\frac{\varepsilon_{B,w}n_B(w)K^{|B|}}{1-\varepsilon_{B,w}}\in(0,\infty]. g ( B , w ) := 1 − ε B , w ε B , w n B ( w ) K ∣ B ∣ ∈ ( 0 , ∞ ] .
with g = ∞ g=\infty g = ∞ if and only if ε B , w = 1 \varepsilon_{B,w}=1 ε B , w = 1 (we recall that ε B , w > 0 \varepsilon_{B,w}>0 ε B , w > 0 by (37) ). Let now ∣ A ∣ ≤ d − 2 |A|\le d-2 ∣ A ∣ ≤ d − 2 , j ∉ A j\notin A j ∈ / A and a ′ a' a ′ with
m ′ : = n A ∪ { j } ( v , a ′ ) > 0 ; m':=n_{A\cup\{j\}}(v,a')>0; m ′ := n A ∪ { j } ( v , a ′ ) > 0 ;
then n A ( v ) ≥ m ′ > 0 n_A(v)\ge m'>0 n A ( v ) ≥ m ′ > 0 and, denoting for simplicity ε \varepsilon ε the parameter ε A , v \varepsilon_{A,v} ε A , v , and ε ′ \varepsilon' ε ′ the parameter ε A ∪ { j } , ( v , a ′ ) \varepsilon_{A\cup\{j\},(v,a')} ε A ∪ { j } , ( v , a ′ ) , we have ψ ^ ( A , v , j ) ( a ′ ) = ( 1 − ε ) m ′ n A ( v ) + ε ′ K \widehat{\psi}_{(A,v,j)}(a')=\frac{(1-\varepsilon)m'}{n_A(v)}+\frac{\varepsilon'}{K} ψ ( A , v , j ) ( a ′ ) = n A ( v ) ( 1 − ε ) m ′ + K ε ′ , so that (39) becomes
ε ( 1 − ε ′ ) K = ( 1 − ε ) ε ′ m ′ n A ( v ) . \frac{\varepsilon(1-\varepsilon')}{K}=\frac{(1-\varepsilon)\varepsilon'm'}{n_A(v)}. K ε ( 1 − ε ′ ) = n A ( v ) ( 1 − ε ) ε ′ m ′ .
i.e.
ε n A ( v ) K ∣ A ∣ ( 1 − ε ′ ) = ( 1 − ε ) ε ′ m ′ K ∣ A ∣ + 1 . (40) \varepsilon n_A(v)K^{|A|}(1-\varepsilon')=(1-\varepsilon)\varepsilon'm'K^{|A|+1}. \tag*{(40)} ε n A ( v ) K ∣ A ∣ ( 1 − ε ′ ) = ( 1 − ε ) ε ′ m ′ K ∣ A ∣ + 1 . (40)
If both ε \varepsilon ε and ε ′ \varepsilon' ε ′ are less than 1, (40) says g ( A , v ) = g ( A ∪ { j } , ( v , a ′ ) ) g(A,v)=g(A\cup\{j\},(v,a')) g ( A , v ) = g ( A ∪ { j } , ( v , a ′ )) . Furthermore, if ε = 1 \varepsilon=1 ε = 1 the left side vanishes, so ε ′ = 1 \varepsilon'=1 ε ′ = 1 since m ′ > 0 m'>0 m ′ > 0 ; finally, if ε ′ = 1 \varepsilon'=1 ε ′ = 1 the right side vanishes, so ε = 1 \varepsilon=1 ε = 1 ; in both cases g ( A , v ) = g ( A ∪ { j } , ( v , a ′ ) ) = ∞ g(A,v)=g(A\cup\{j\},(v,a'))=\infty g ( A , v ) = g ( A ∪ { j } , ( v , a ′ )) = ∞ . Hence g ( A , v ) = g ( A ∪ { j } , ( v , a ′ ) ) g(A,v)=g(A\cup\{j\},(v,a')) g ( A , v ) = g ( A ∪ { j } , ( v , a ′ )) in every case.
We notice now that any ( B , w ) (B,w) ( B , w ) with n B ( w ) > 0 n_B(w)>0 n B ( w ) > 0 and ∣ B ∣ ≤ d − 1 |B|\le d-1 ∣ B ∣ ≤ d − 1 is obtained from ( ∅ , ∅ ) (\varnothing,\varnothing) ( ∅ , ∅ ) by adding the coordinates of B B B one at a time. Additionally, every intermediate pair ( B ′ , w B ′ ) (B',w_{B'}) ( B ′ , w B ′ ) satisfies n B ′ ( w B ′ ) ≥ n B ( w ) > 0 n_{B'}(w_{B'})\ge n_B(w)>0 n B ′ ( w B ′ ) ≥ n B ( w ) > 0 and ∣ B ′ ∣ ≤ d − 2 |B'|\le d-2 ∣ B ′ ∣ ≤ d − 2 before the last step, hence the previous paragraph applies at each step and g ( B , w ) = g ( ∅ , ∅ ) = : γ ∈ ( 0 , ∞ ] g(B,w)=g(\varnothing,\varnothing)=:\gamma\in(0,\infty] g ( B , w ) = g ( ∅ , ∅ ) =: γ ∈ ( 0 , ∞ ] . Note moreover that n ∅ ( ∅ ) = n n_{\varnothing}(\varnothing)=n n ∅ ( ∅ ) = n .
Solving g ( B , w ) = γ g(B,w)=\gamma g ( B , w ) = γ for ε B , w \varepsilon_{B,w} ε B , w gives
ε B , w = γ K − ∣ B ∣ γ K − ∣ B ∣ + n B ( w ) . \varepsilon_{B,w}=\frac{\gamma K^{-|B|}}{\gamma K^{-|B|}+n_B(w)}. ε B , w = γ K − ∣ B ∣ + n B ( w ) γ K − ∣ B ∣ .
which is (14) for all c c c with n c > 0 n_c>0 n c > 0 ; in the case n c = 0 n_c=0 n c = 0 we have ε c = 1 \varepsilon_c=1 ε c = 1 by assumption, which is again (14) . To finish, by the if part above, ( ψ ^ c ) c (\widehat{\psi}_c)_c ( ψ c ) c are the conditionals of μ ^ 0 \widehat{\mu}_0 μ 0 , so μ ˉ = μ ^ 0 \bar{\mu}=\widehat{\mu}_0 μ ˉ = μ 0 by the uniqueness above. □
Lemma 8. Consider the masked kernel. Let s ( x , y , t ) = κ t ψ c ( y , i ) ( x i ) s(x,y,t)=\kappa_t\psi_{c(y,i)}(x_i) s ( x , y , t ) = κ t ψ c ( y , i ) ( x i ) with x = ( y − i , x i ) x=(y_{-i},x_i) x = ( y − i , x i ) , ψ c ∈ P ( V ) \psi_c\in\mathcal{P}(\mathcal{V}) ψ c ∈ P ( V ) for every context c c c , and for k ∈ { 0 , … , d − 1 } k\in\{0,\ldots,d-1\} k ∈ { 0 , … , d − 1 } set
ω k : = ∫ 0 T σ t α t k + 1 ( 1 − α t ) d − k − 1 d t ∈ ( 0 , ∞ ) . \omega_k:=\int_0^T\sigma_t\alpha_t^{k+1}(1-\alpha_t)^{d-k-1}\,\mathrm{d}t\in(0,\infty). ω k := ∫ 0 T σ t α t k + 1 ( 1 − α t ) d − k − 1 d t ∈ ( 0 , ∞ ) . Then
∫ 0 T L ^ t ( s ) d t = ∑ c ω ∣ A ∣ n c n H ( ψ c ( n ) , ψ c ) + C n , \int_0^T\widehat{L}_t(s)\,\mathrm{d}t=\sum_c\omega_{|A|}\frac{n_c}{n}H(\psi_c^{(n)},\psi_c)+C_n, ∫ 0 T L t ( s ) d t = c ∑ ω ∣ A ∣ n n c H ( ψ c ( n ) , ψ c ) + C n , ∫ 0 T L t U ( s ) d t = ∑ c ω ∣ A ∣ K − ∣ A ∣ H ( Unif ( V ) , ψ c ) + C U , \int_0^T L_t^U(s)\,\mathrm{d}t=\sum_c\omega_{|A|}K^{-|A|}H(\operatorname{Unif}(\mathcal{V}),\psi_c)+C_U, ∫ 0 T L t U ( s ) d t = c ∑ ω ∣ A ∣ K − ∣ A ∣ H ( Unif ( V ) , ψ c ) + C U , where C n , C U ∈ R C_n,C_U\in\mathbb{R} C n , C U ∈ R do not depend on ( ψ c ) c (\psi_c)_c ( ψ c ) c . It follows also then that, for every γ > 0 \gamma>0 γ > 0 , with ε c \varepsilon_c ε c as in (14) ,
∫ 0 T L ^ t M ( s ) d t = ∑ c ω ∣ A ∣ n c + γ K − ∣ A ∣ n + γ [ ( 1 − ε c ) H ( ψ c ( n ) , ψ c ) + ε c H ( Unif ( V ) , ψ c ) ] + n C n + γ C U n + γ \int_0^T\widehat{L}_t^M(s)\,\mathrm{d}t=\sum_c\omega_{|A|}\frac{n_c+\gamma K^{-|A|}}{n+\gamma}\left[(1-\varepsilon_c)H(\psi_c^{(n)},\psi_c)+\varepsilon_c H(\operatorname{Unif}(\mathcal{V}),\psi_c)\right]+\frac{nC_n+\gamma C_U}{n+\gamma} ∫ 0 T L t M ( s ) d t = c ∑ ω ∣ A ∣ n + γ n c + γ K − ∣ A ∣ [ ( 1 − ε c ) H ( ψ c ( n ) , ψ c ) + ε c H ( Unif ( V ) , ψ c ) ] + n + γ n C n + γ C U
which is minimized, uniquely, at ψ c = ψ ^ c = ( 1 − ε c ) ψ c ( n ) + ε c Unif ( V ) \psi_c=\hat{\psi}_c=(1-\varepsilon_c)\psi_c^{(n)}+\varepsilon_c\operatorname{Unif}(\mathcal{V}) ψ c = ψ ^ c = ( 1 − ε c ) ψ c ( n ) + ε c Unif ( V ) for every c c c . In a similar way, the first identity is minimized, uniquely, on the contexts with n c > 0 n_c>0 n c > 0 , at ψ c = ψ c ( n ) \psi_c=\psi_c^{(n)} ψ c = ψ c ( n ) , while contexts with n c = 0 n_c=0 n c = 0 are unconstrained.
Proof. We fix t ∈ ( 0 , T ] t\in(0,T] t ∈ ( 0 , T ] . For the masked kernel, Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 with x ≠ y x\ne y x = y if and only if x = ( y − i , a ) x=(y_{-i},a) x = ( y − i , a ) for some i ∈ M ( y ) i\in M(y) i ∈ M ( y ) and a ∈ V a\in\mathcal{V} a ∈ V : in this case, Q t ( y , x ) = σ t Q_t(y,x)=\sigma_t Q t ( y , x ) = σ t . Taking the average over the sample in (8) and using that 1 n ∑ k P 0 , t ( y , X 0 ( k ) ) = μ t ( n ) ( y ) \frac{1}{n}\sum_k P_{0,t}(y,X_0^{(k)})=\mu_t^{(n)}(y) n 1 ∑ k P 0 , t ( y , X 0 ( k ) ) = μ t ( n ) ( y ) , 1 n ∑ k P 0 , t ( x , X 0 ( k ) ) = μ t ( n ) ( x ) \frac{1}{n}\sum_k P_{0,t}(x,X_0^{(k)})=\mu_t^{(n)}(x) n 1 ∑ k P 0 , t ( x , X 0 ( k ) ) = μ t ( n ) ( x ) , we get
L ^ t ( s ) = σ t ∑ y ∈ X ∑ i ∈ M ( y ) ∑ a ∈ V [ μ t ( n ) ( y ) s ( x , y , t ) − μ t ( n ) ( x ) log s ( x , y , t ) ] , x = ( y − i , a ) . (41) \hat{L}_t(s)=\sigma_t\sum_{y\in\mathcal{X}}\sum_{i\in M(y)}\sum_{a\in\mathcal{V}}\left[\mu_t^{(n)}(y)s(x,y,t)-\mu_t^{(n)}(x)\log s(x,y,t)\right],\qquad x=(y_{-i},a). \tag*{(41)} L ^ t ( s ) = σ t y ∈ X ∑ i ∈ M ( y ) ∑ a ∈ V ∑ [ μ t ( n ) ( y ) s ( x , y , t ) − μ t ( n ) ( x ) log s ( x , y , t ) ] , x = ( y − i , a ) . (41)
Fix y y y with M ( y ) ≠ ∅ M(y)\ne\varnothing M ( y ) = ∅ , i ∈ M ( y ) i\in M(y) i ∈ M ( y ) , and let c = ( A , v , i ) c=(A,v,i) c = ( A , v , i ) with A = A ( y ) A=A(y) A = A ( y ) , v = y A v=y_A v = y A . By the product form of P 0 , t mask P_{0,t}^{\operatorname{mask}} P 0 , t mask ,
μ t ( n ) ( y ) = α t ∣ A ∣ ( 1 − α t ) d − ∣ A ∣ n c n . \mu_t^{(n)}(y)=\alpha_t^{|A|}(1-\alpha_t)^{d-|A|}\frac{n_c}{n}. μ t ( n ) ( y ) = α t ∣ A ∣ ( 1 − α t ) d − ∣ A ∣ n n c .
and
μ t ( n ) ( x ) = α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 n c ψ c ( n ) ( a ) n . \mu_t^{(n)}(x)=\alpha_t^{|A|+1}(1-\alpha_t)^{d-|A|-1}n_c\frac{\psi_c^{(n)}(a)}{n}. μ t ( n ) ( x ) = α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 n c n ψ c ( n ) ( a ) .
In both cases, they vanish if n c = 0 n_c=0 n c = 0 . Since by definition κ t = α t 1 − α t \kappa_t=\frac{\alpha_t}{1-\alpha_t} κ t = 1 − α t α t and ∑ a ψ c ( a ) = ∑ a ψ c ( n ) ( a ) = 1 \sum_a\psi_c(a)=\sum_a\psi_c^{(n)}(a)=1 ∑ a ψ c ( a ) = ∑ a ψ c ( n ) ( a ) = 1 , the inner sum over a a a in (41) equals
α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 n c n [ 1 − log κ t + H ( ψ c ( n ) , ψ c ) ] . \alpha_t^{|A|+1}(1-\alpha_t)^{d-|A|-1}\frac{n_c}{n}\left[1-\log\kappa_t+H(\psi_c^{(n)},\psi_c)\right]. α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 n n c [ 1 − log κ t + H ( ψ c ( n ) , ψ c ) ] .
As ( y , i ) ↦ c ( y , i ) (y,i)\mapsto c(y,i) ( y , i ) ↦ c ( y , i ) is a bijection between { ( y , i ) : y ∈ X , i ∈ M ( y ) } \{(y,i):y\in\mathcal{X},\,i\in M(y)\} {( y , i ) : y ∈ X , i ∈ M ( y )} and the set of contexts,
L ^ t ( s ) = ∑ c σ t α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 n c n [ 1 − log κ t + H ( ψ c ( n ) , ψ c ) ] . \hat{L}_t(s)=\sum_c\sigma_t\alpha_t^{|A|+1}(1-\alpha_t)^{d-|A|-1}\frac{n_c}{n}\left[1-\log\kappa_t+H(\psi_c^{(n)},\psi_c)\right]. L ^ t ( s ) = c ∑ σ t α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 n n c [ 1 − log κ t + H ( ψ c ( n ) , ψ c ) ] .
Integrating in t t t gives the first identity of the statement with
C n : = ∑ c n c n ∫ 0 T σ t α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 ( 1 − log κ t ) d t . C_n:=\sum_c\frac{n_c}{n}\int_0^T\sigma_t\alpha_t^{|A|+1}(1-\alpha_t)^{d-|A|-1}(1-\log\kappa_t)\,dt. C n := c ∑ n n c ∫ 0 T σ t α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 ( 1 − log κ t ) d t .
To check that ω k \omega_k ω k and C n C_n C n are finite, substitute u = σ ˉ t u=\bar{\sigma}t u = σ ˉ t , with σ t d t = d u \sigma_t\,dt=du σ t d t = d u , α t = e − u \alpha_t=e^{-u} α t = e − u :
ω k = ∫ 0 σ ˉ T e − ( k + 1 ) u ( 1 − e − u ) d − k − 1 d u ∈ ( 0 , σ ˉ T ] , \omega_k=\int_0^{\bar{\sigma}T}e^{-(k+1)u}(1-e^{-u})^{d-k-1}\,du\in(0,\bar{\sigma}T], ω k = ∫ 0 σ ˉ T e − ( k + 1 ) u ( 1 − e − u ) d − k − 1 d u ∈ ( 0 , σ ˉ T ] ,
and since 1 − e − u ≥ u / 2 1-e^{-u}\ge u/2 1 − e − u ≥ u /2 for u ≤ 1 u\le1 u ≤ 1 and 1 − e − u ≥ 1 / 2 1-e^{-u}\ge1/2 1 − e − u ≥ 1/2 for u ≥ 1 u\ge1 u ≥ 1 we have that log κ t = − u − log ( 1 − e − u ) \log\kappa_t=-u-\log(1-e^{-u}) log κ t = − u − log ( 1 − e − u ) with ∣ log ( 1 − e − u ) ∣ ≤ log 2 + ∣ log u ∣ |\log(1-e^{-u})|\le\log2+|\log u| ∣ log ( 1 − e − u ) ∣ ≤ log 2 + ∣ log u ∣ , so the integrand of C n C_n C n is bounded by e − ( k + 1 ) u ( 1 + u + log 2 + ∣ log u ∣ ) e^{-(k+1)u}(1+u+\log2+|\log u|) e − ( k + 1 ) u ( 1 + u + log 2 + ∣ log u ∣ ) , which is integrable on ( 0 , σ ˉ T ) (0,\bar{\sigma}T) ( 0 , σ ˉ T ) .
Moreover, if we run the same computations as above with μ 0 ( n ) \mu_0^{(n)} μ 0 ( n ) replaced by Unif ( X 0 ) \operatorname{Unif}(\mathcal{X}_0) Unif ( X 0 ) (for which Unif ( X A = v ) = K − ∣ A ∣ \operatorname{Unif}(X_A=v)=K^{-|A|} Unif ( X A = v ) = K − ∣ A ∣ and the conditional law of X i X_i X i given X A = v X_A=v X A = v is Unif ( V ) \operatorname{Unif}(\mathcal{V}) Unif ( V ) ), the second identity follows. We observe that the term ϕ ( s t U ) \phi(s_t^U) ϕ ( s t U ) in (7) does not depend on s s s and is absorbed in C U C_U C U .
Finally, the identity for
L ^ t M = n n + γ L ^ t + γ n + γ L t U \hat{L}_t^M=\frac{n}{n+\gamma}\hat{L}_t+\frac{\gamma}{n+\gamma}L_t^U L ^ t M = n + γ n L ^ t + n + γ γ L t U
follows since
n n + γ n c n = n c + γ K − ∣ A ∣ n + γ ( 1 − ε c ) \frac{n}{n+\gamma}\frac{n_c}{n}=\frac{n_c+\gamma K^{-|A|}}{n+\gamma}(1-\varepsilon_c) n + γ n n n c = n + γ n c + γ K − ∣ A ∣ ( 1 − ε c )
and
γ n + γ K − ∣ A ∣ = n c + γ K − ∣ A ∣ n + γ ε c . \frac{\gamma}{n+\gamma}K^{-|A|}=\frac{n_c+\gamma K^{-|A|}}{n+\gamma}\varepsilon_c. n + γ γ K − ∣ A ∣ = n + γ n c + γ K − ∣ A ∣ ε c .
To finish, all weights ω ∣ A ∣ ( n c + γ K − ∣ A ∣ ) n + γ \frac{\omega_{|A|}(n_c+\gamma K^{-|A|})}{n+\gamma} n + γ ω ∣ A ∣ ( n c + γ K − ∣ A ∣ ) are positive and the cross-entropy is linear in its first argument, hence
( 1 − ε ) H ( p , q ) + ε H ( u , q ) = H ( ( 1 − ε ) p + ε u , q ) , (1-\varepsilon)H(p,q)+\varepsilon H(u,q)=H((1-\varepsilon)p+\varepsilon u,q), ( 1 − ε ) H ( p , q ) + ε H ( u , q ) = H (( 1 − ε ) p + ε u , q ) ,
and H ( p , q ) = H ( p , p ) + KL ( p ∣ q ) ≥ H ( p , p ) H(p,q)=H(p,p)+\operatorname{KL}(p\mathbin{|}q)\ge H(p,p) H ( p , q ) = H ( p , p ) + KL ( p ∣ q ) ≥ H ( p , p ) with equality if and only if q = p q=p q = p . This gives the two minimization statements.
Proofs of Section 3.2
To begin, we recall here that a context c c c is a triple ( A , v , i ) (A,v,i) ( A , v , i ) , where A ⊆ [ d ] A\subseteq[d] A ⊆ [ d ] , v ∈ V A v\in\mathcal{V}^{A} v ∈ V A and i ∈ [ d ] ∖ A i\in[d]\setminus A i ∈ [ d ] ∖ A . In particular, given a certain state y ∈ X y\in\mathcal{X} y ∈ X , we will often call c ( y , i ) c(y,i) c ( y , i ) , or for brevity when it isn’t ambiguous c c c , the triple ( A ( y ) , y A ( y ) , i ) (A(y),y_{A(y)},i) ( A ( y ) , y A ( y ) , i ) , where A ( y ) A(y) A ( y ) are the positions of unmasked tokens in y y y . We will denote also by M ( y ) : = [ d ] ∖ A ( y ) M(y):=[d]\setminus A(y) M ( y ) := [ d ] ∖ A ( y ) , the position of the masked tokens in y y y . Given a position i ∈ [ d ] i\in[d] i ∈ [ d ] , a token x i ∈ V x_i\in\mathcal{V} x i ∈ V , and a state y ∈ X y\in\mathcal{X} y ∈ X such that y i = m y_i=\mathrm{m} y i = m , we can then define for a generic ρ \rho ρ the following conditional probability ψ c ( a ) : = ρ ( X A = v , X i = a ) ρ ( X A = v ) \psi_c(a):=\frac{\rho(X_A=v,X_i=a)}{\rho(X_A=v)} ψ c ( a ) := ρ ( X A = v ) ρ ( X A = v , X i = a ) , when ρ ( X A = v ) > 0 \rho(X_A=v)>0 ρ ( X A = v ) > 0 .
We first introduce here a key result from Ou et al. [14 ] . It tells us that the score depends on time through an universal and explicit constant, and the data-dependence is independent from time and noise.
Proposition 2 (Ou et al. [14 ] , Theorem 1). Let ρ ∈ P ( X 0 ) \rho\in\mathcal{P}(\mathcal{X}_0) ρ ∈ P ( X 0 ) , and ρ t : = P 0 , t m a s k ρ \rho_t:=P^{\mathrm{mask}}_{0,t}\rho ρ t := P 0 , t mask ρ . For every t ∈ ( 0 , T ] t\in(0,T] t ∈ ( 0 , T ] , every y ∈ X y\in\mathcal{X} y ∈ X with ρ t ( y ) > 0 \rho_t(y)>0 ρ t ( y ) > 0 (equivalently ρ ( X A ( y ) = y A ( y ) ) > 0 \rho(X_{A(y)}=y_{A(y)})>0 ρ ( X A ( y ) = y A ( y ) ) > 0 ), every i ∈ M ( y ) i\in M(y) i ∈ M ( y ) and a ∈ V a\in\mathcal{V} a ∈ V ,
ρ t ( x ) ρ t ( y ) = κ t ρ ( X i = a ∣ X A ( y ) = y A ( y ) ) , x : = ( y − i , a ) , κ t = α t 1 − α t . \frac{\rho_t(x)}{\rho_t(y)}=\kappa_t\rho(X_i=a\mid X_{A(y)}=y_{A(y)}),\qquad x:=(y_{-i},a),\quad\kappa_t=\frac{\alpha_t}{1-\alpha_t}. ρ t ( y ) ρ t ( x ) = κ t ρ ( X i = a ∣ X A ( y ) = y A ( y ) ) , x := ( y − i , a ) , κ t = 1 − α t α t .
Proof. The proof follows immediately from the structure of P 0 , t m a s k P^{\mathrm{mask}}_{0,t} P 0 , t mask : in fact,
ρ t ( y ) = α t ∣ A ∣ ( 1 − α t ) d − ∣ A ∣ ρ ( X A = y A ) \rho_t(y)=\alpha_t^{|A|}(1-\alpha_t)^{d-|A|}\rho(X_A=y_A) ρ t ( y ) = α t ∣ A ∣ ( 1 − α t ) d − ∣ A ∣ ρ ( X A = y A )
with A = A ( y ) A=A(y) A = A ( y ) , and
ρ t ( x ) = α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 ρ ( X A = y A , X i = a ) . \rho_t(x)=\alpha_t^{|A|+1}(1-\alpha_t)^{d-|A|-1}\rho(X_A=y_A,X_i=a). ρ t ( x ) = α t ∣ A ∣ + 1 ( 1 − α t ) d − ∣ A ∣ − 1 ρ ( X A = y A , X i = a ) .
Dividing, we conclude.
Let us now define an important object. Given a score s s s (measurable in t t t , positive where Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 ) define the excess score entropy
E t ( s ) : = ∑ y ∈ X μ t ( y ) ∑ x ≠ y Q t ( y , x ) D ( s ⋆ ( x , y , t ) , s ( x , y , t ) ) ∈ [ 0 , ∞ ] , (42) \mathcal{E}_t(s):=\sum_{y\in\mathcal{X}}\mu_t(y)\sum_{x\ne y}Q_t(y,x)D(s^\star(x,y,t),s(x,y,t))\in[0,\infty], \tag*{(42)} E t ( s ) := y ∈ X ∑ μ t ( y ) x = y ∑ Q t ( y , x ) D ( s ⋆ ( x , y , t ) , s ( x , y , t )) ∈ [ 0 , ∞ ] , (42)
with D D D as above (and D ( a , 0 ) = + ∞ D(a,0)=+\infty D ( a , 0 ) = + ∞ for a > 0 a>0 a > 0 , D ( 0 , 0 ) = 0 D(0,0)=0 D ( 0 , 0 ) = 0 ). Expanding D D D and using μ t ( y ) s ⋆ ( x , y , t ) = μ t ( x ) \mu_t(y)s^\star(x,y,t)=\mu_t(x) μ t ( y ) s ⋆ ( x , y , t ) = μ t ( x ) whenever Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 , one checks that E t ( s ) = L t ( s ) \mathcal{E}_t(s)=L_t(s) E t ( s ) = L t ( s ) , with L t L_t L t the score-entropy loss (7); in particular L t ( s ⋆ ) = 0 L_t(s^\star)=0 L t ( s ⋆ ) = 0 and L t ≥ 0 L_t\ge0 L t ≥ 0 .
Throughout the section, many results hold also for the uniform case. For this reason we give already now their lemmas and proofs.
Lemma 9 (Bounds on the uniform score). Consider the uniform kernel, γ > 0 \gamma> 0 γ > 0 , and s ^ \hat{s} s ^ the score for the uniform case. Then, for all t ∈ [ 0 , T ] t \in[0,T] t ∈ [ 0 , T ] and x , y ∈ X 0 x,y \in\mathcal{X}_0 x , y ∈ X 0 ,
M γ − 1 ≤ s ^ ( x , y , t ) ≤ M γ , M γ : = K d ( n + γ ) γ , M_\gamma^{-1} \le\hat{s}(x,y,t) \le M_\gamma,\qquad M_\gamma:= \frac{K^d(n+\gamma)}{\gamma}, M γ − 1 ≤ s ^ ( x , y , t ) ≤ M γ , M γ := γ K d ( n + γ ) , and t ↦ s ^ ( x , y , t ) t \mapsto\hat{s}(x,y,t) t ↦ s ^ ( x , y , t ) is continuous. Moreover, for 0 < T 0 ≤ T 0 < T_0 \le T 0 < T 0 ≤ T ,
s ⋆ ( x , y , t ) ≤ K d ( 1 − α T 0 ) d s^\star(x,y,t) \le\frac{K^d}{(1-\alpha T_0)^d} s ⋆ ( x , y , t ) ≤ ( 1 − α T 0 ) d K d for all t ∈ [ T 0 , T ] t \in[T_0,T] t ∈ [ T 0 , T ] and every x , y ∈ X 0 x,y \in\mathcal{X}_0 x , y ∈ X 0 .
Proof. Since we consider the uniform kernel, we know that Q 0 u n i f Q_0^{\mathrm{unif}} Q 0 unif is symmetric, so P 0 , t = e σ ˉ t Q 0 P_{0,t}=e^{\bar{\sigma}_t Q_0} P 0 , t = e σ ˉ t Q 0 is symmetric with unit column sums, or equivalently it is doubly stochastic. Hence
μ ^ t ( x ) = ∑ x 0 P 0 , t ( x , x 0 ) μ ^ 0 ( γ ) ( x 0 ) \hat{\mu}_t(x)=\sum_{x_0}P_{0,t}(x,x_0)\hat{\mu}_0^{(\gamma)}(x_0) μ ^ t ( x ) = x 0 ∑ P 0 , t ( x , x 0 ) μ ^ 0 ( γ ) ( x 0 )
is a convex combination of the values of μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) , thus
γ K d ( n + γ ) = min μ ^ 0 ( γ ) ≤ μ ^ t ( x ) ≤ max μ ^ 0 ( γ ) ≤ 1 \frac{\gamma}{K^d(n+\gamma)}=\min\hat{\mu}_0^{(\gamma)}\le\hat{\mu}_t(x)\le\max\hat{\mu}_0^{(\gamma)}\le1 K d ( n + γ ) γ = min μ ^ 0 ( γ ) ≤ μ ^ t ( x ) ≤ max μ ^ 0 ( γ ) ≤ 1
Now, dividing we get the two-sided bound and the continuity in t t t is follows quickly. To end, for s ⋆ s^\star s ⋆ , we have that μ t ( x ) ≤ 1 \mu_t(x)\le1 μ t ( x ) ≤ 1 and
μ t ( y ) ≥ min x 0 P 0 , t ( y , x 0 ) ≥ ( 1 − α t K ) d ≥ ( 1 − α T 0 K ) d \mu_t(y)\ge\min_{x_0}P_{0,t}(y,x_0)\ge\left(\frac{1-\alpha_t}{K}\right)^d\ge\left(\frac{1-\alpha T_0}{K}\right)^d μ t ( y ) ≥ x 0 min P 0 , t ( y , x 0 ) ≥ ( K 1 − α t ) d ≥ ( K 1 − α T 0 ) d
on [ T 0 , T ] [T_0,T] [ T 0 , T ] .
Lemma 10 (Excess score entropy along the forward flow). Consider the uniform kernel, γ > 0 \gamma> 0 γ > 0 , 0 < T 0 ≤ T 0<T_0\le T 0 < T 0 ≤ T , μ ^ t : = P 0 , t μ ^ 0 ( γ ) \hat{\mu}_t:=P_{0,t}\hat{\mu}_0^{(\gamma)} μ ^ t := P 0 , t μ ^ 0 ( γ ) , and s ^ \hat{s} s ^ as in (24). Then, the map t ↦ K L ( μ t ∣ μ ^ t ) t\mapsto\mathrm{KL}(\mu_t\mid\hat{\mu}_t) t ↦ KL ( μ t ∣ μ ^ t ) is absolutely continuous on [ T 0 , T ] [T_0,T] [ T 0 , T ] , for a.e. t ∈ [ T 0 , T ] t\in[T_0,T] t ∈ [ T 0 , T ] and it holds
d d t K L ( μ t ∣ μ ^ t ) = − E t ( s ^ ) = − L t ( s ^ ) . \frac{\mathrm{d}}{\mathrm{d}t}\mathrm{KL}(\mu_t\mid\hat{\mu}_t)=-\mathcal{E}_t(\hat{s})=-\mathcal{L}_t(\hat{s}). d t d KL ( μ t ∣ μ ^ t ) = − E t ( s ^ ) = − L t ( s ^ ) . Consequently,
∫ T 0 T L t ( s ^ ) d t = K L ( μ T 0 ∣ μ ^ T 0 ) − K L ( μ T ∣ μ ^ T ) ≤ K L ( μ T 0 ∣ μ ^ T 0 ) ≤ K L ( μ d a t a ∣ μ ^ 0 ( γ ) ) . \int_{T_0}^{T}\mathcal{L}_t(\hat{s})\mathrm{d}t=\mathrm{KL}(\mu_{T_0}\mid\hat{\mu}_{T_0})-\mathrm{KL}(\mu_T\mid\hat{\mu}_T)\le\mathrm{KL}(\mu_{T_0}\mid\hat{\mu}_{T_0})\le\mathrm{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)}). ∫ T 0 T L t ( s ^ ) d t = KL ( μ T 0 ∣ μ ^ T 0 ) − KL ( μ T ∣ μ ^ T ) ≤ KL ( μ T 0 ∣ μ ^ T 0 ) ≤ KL ( μ data ∣ μ ^ 0 ( γ ) ) .
Proof. To begin, we apply Lemma 6 on [ T 0 , T ] [T_0,T] [ T 0 , T ] with A t = B t = Q t = σ t Q 0 A_t=B_t=Q_t=\sigma_tQ_0 A t = B t = Q t = σ t Q 0 , p t = μ t p_t=\mu_t p t = μ t , q t = μ ^ t q_t=\hat{\mu}_t q t = μ ^ t and ∫ σ < ∞ \int\sigma<\infty ∫ σ < ∞ : we observe that
q T 0 = μ ^ T 0 > 0 q_{T_0}=\hat{\mu}_{T_0}>0 q T 0 = μ ^ T 0 > 0
because μ ^ 0 ( γ ) > 0 \hat{\mu}_0^{(\gamma)}>0 μ ^ 0 ( γ ) > 0 and Lemma 7. Moreover, again thanks to Lemma 7, the support of μ t \mu_t μ t is X 0 \mathcal{X}_0 X 0 for every t > 0 t>0 t > 0 , hence it is constant. Calling for simplicity r t : = μ t μ ^ t > 0 r_t:=\frac{\mu_t}{\hat{\mu}_t}>0 r t := μ ^ t μ t > 0 , by (30), for a.e. t t t , we have
d d t K L ( μ t ∣ μ ^ t ) = ∑ y ∑ x ≠ y Q t ( x , y ) [ μ t ( y ) log r t ( x ) r t ( y ) − μ ^ t ( y ) ( r t ( x ) − r t ( y ) ) ] = ∑ y μ t ( y ) ∑ x ≠ y Q t ( x , y ) ( log r t ( x ) r t ( y ) − r t ( x ) r t ( y ) + 1 ) , \begin{aligned}
\frac{\mathrm{d}}{\mathrm{d}t}\mathrm{KL}(\mu_t\mid\hat{\mu}_t)
&=\sum_y\sum_{x\ne y}Q_t(x,y)\left[\mu_t(y)\log\frac{r_t(x)}{r_t(y)}-\hat{\mu}_t(y)\bigl(r_t(x)-r_t(y)\bigr)\right]\\
&=\sum_y\mu_t(y)\sum_{x\ne y}Q_t(x,y)\left(\log\frac{r_t(x)}{r_t(y)}-\frac{r_t(x)}{r_t(y)}+1\right),
\end{aligned} d t d KL ( μ t ∣ μ ^ t ) = y ∑ x = y ∑ Q t ( x , y ) [ μ t ( y ) log r t ( y ) r t ( x ) − μ ^ t ( y ) ( r t ( x ) − r t ( y ) ) ] = y ∑ μ t ( y ) x = y ∑ Q t ( x , y ) ( log r t ( y ) r t ( x ) − r t ( y ) r t ( x ) + 1 ) ,
where above we used μ ^ t ( y ) = μ t ( y ) / r t ( y ) \hat{\mu}_t(y) = \mu_t(y)/r_t(y) μ ^ t ( y ) = μ t ( y ) / r t ( y ) and that r t ( x ) r t ( y ) = s ⋆ ( x , y , t ) s ^ ( x , y , t ) ∈ ( 0 , ∞ ) \frac{r_t(x)}{r_t(y)} = \frac{s^\star(x,y,t)}{\hat{s}(x,y,t)} \in(0,\infty) r t ( y ) r t ( x ) = s ^ ( x , y , t ) s ⋆ ( x , y , t ) ∈ ( 0 , ∞ ) . Exchanging the names of x x x and y y y in the double sum, since μ t ( x ) = μ t ( y ) s ⋆ ( x , y , t ) = μ t ( y ) s ^ ( x , y , t ) r t ( x ) r t ( y ) \mu_t(x) = \mu_t(y)s^\star(x,y,t) = \mu_t(y)\hat{s}(x,y,t)\frac{r_t(x)}{r_t(y)} μ t ( x ) = μ t ( y ) s ⋆ ( x , y , t ) = μ t ( y ) s ^ ( x , y , t ) r t ( y ) r t ( x ) , the summand becomes
μ t ( y ) Q t ( y , x ) s ^ ( x , y , t ) r t ( x ) r t ( y ) ( − log r t ( x ) r t ( y ) − r y ( y ) r t ( x ) + 1 ) = − μ t ( y ) Q t ( y , x ) s ^ ( x , y , t ) h ( r t ( x ) r t ( y ) ) = − μ t ( y ) Q t ( y , x ) D ( s ⋆ ( x , y , t ) , s ^ ( x , y , t ) ) , \begin{aligned}
\mu_t(y)Q_t(y,x)\hat{s}(x,y,t)\frac{r_t(x)}{r_t(y)}\left(-\log\frac{r_t(x)}{r_t(y)}-\frac{r_y(y)}{r_t(x)}+1\right)=-\mu_t(y)Q_t(y,x)\hat{s}(x,y,t)h\left(\frac{r_t(x)}{r_t(y)}\right) \\
&=-\mu_t(y)Q_t(y,x)D\left(s^\star(x,y,t),\hat{s}(x,y,t)\right),
\end{aligned} μ t ( y ) Q t ( y , x ) s ^ ( x , y , t ) r t ( y ) r t ( x ) ( − log r t ( y ) r t ( x ) − r t ( x ) r y ( y ) + 1 ) = − μ t ( y ) Q t ( y , x ) s ^ ( x , y , t ) h ( r t ( y ) r t ( x ) ) = − μ t ( y ) Q t ( y , x ) D ( s ⋆ ( x , y , t ) , s ^ ( x , y , t ) ) ,
where we recall that h ( u ) = u log u − u + 1 h(u) = u\log u-u+1 h ( u ) = u log u − u + 1 and D ( a , b ) = b h ( a / b ) D(a,b)=bh(a/b) D ( a , b ) = bh ( a / b ) . Summing gives − E t ( s ^ ) -\mathcal{E}_t(\hat{s}) − E t ( s ^ ) . Integrating on [ T 0 , T ] [T_0,T] [ T 0 , T ] , using that KL ≥ 0 \operatorname{KL}\ge0 KL ≥ 0 , and finally the data processing inequality, we get the last inequality.
Lemma 11 (Transfer from score error to the sampler output). Let 0 < T 0 < T 0<T_0<T 0 < T 0 < T , μ ∞ ∈ P ( X ) \mu_\infty\in\mathcal{P}(\mathcal{X}) μ ∞ ∈ P ( X ) with μ ∞ > 0 \mu_\infty>0 μ ∞ > 0 on X \mathcal{X} X . Let s s s be a score, measurable in t t t , with sup { s ( x , y , t ) : x , y ∈ X , t ∈ [ T 0 , T ] } < ∞ \sup\{s(x,y,t):x,y\in\mathcal{X},t\in[T_0,T]\}<\infty sup { s ( x , y , t ) : x , y ∈ X , t ∈ [ T 0 , T ]} < ∞ and s ( x , y , t ) > 0 s(x,y,t)>0 s ( x , y , t ) > 0 whenever s ⋆ ( x , y , t ) Q t ( y , x ) > 0 s^\star(x,y,t)Q_t(y,x)>0 s ⋆ ( x , y , t ) Q t ( y , x ) > 0 . Moreover, let ( ν u ) u ∈ [ 0 , T − T 0 ] (\nu_u)_{u\in[0,T-T_0]} ( ν u ) u ∈ [ 0 , T − T 0 ] be the solution of (6) with score s s s and initial law ν 0 = μ ∞ \nu_0=\mu_\infty ν 0 = μ ∞ . Then
KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ T ∣ μ ∞ ) + ∫ T 0 T E t ( s ) d t . (43) \operatorname{KL}(\mu_{T_0}\mid\nu_{T-T_0})\leq\operatorname{KL}(\mu_T\mid\mu_\infty)+\int_{T_0}^{T}\mathcal{E}_t(s)\,dt. \tag*{(43)} KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ T ∣ μ ∞ ) + ∫ T 0 T E t ( s ) d t . (43) In particular, for the uniform kernel, μ ∞ = Unif ( X 0 ) \mu_\infty=\operatorname{Unif}(\mathcal{X}_0) μ ∞ = Unif ( X 0 ) and s = s ^ s=\hat{s} s = s ^ of (24), the hypotheses hold by Lemma 9 and (42) reads KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ T ∣ Unif ( X 0 ) ) + ∫ T 0 T L t ( s ^ ) d t \operatorname{KL}(\mu_{T_0}\mid\nu_{T-T_0})\leq\operatorname{KL}(\mu_T\mid\operatorname{Unif}(\mathcal{X}_0))+\int_{T_0}^{T}L_t(\hat{s})\,dt KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ T ∣ Unif ( X 0 )) + ∫ T 0 T L t ( s ^ ) d t .
Proof. To start, we set τ : = T − T 0 \tau:=T-T_0 τ := T − T 0 and, for u ∈ [ 0 , τ ] u\in[0,\tau] u ∈ [ 0 , τ ] and x ≠ y x\ne y x = y ,
Q ~ u ( x , y ) : = s ⋆ ( x , y , T − u ) Q T − u ( y , x ) , Q ^ u ( x , y ) : = s ( x , y , T − u ) Q T − u ( y , x ) , \widetilde{Q}_u(x,y):=s^\star(x,y,T-u)Q_{T-u}(y,x),\qquad\widehat{Q}_u(x,y):=s(x,y,T-u)Q_{T-u}(y,x), Q u ( x , y ) := s ⋆ ( x , y , T − u ) Q T − u ( y , x ) , Q u ( x , y ) := s ( x , y , T − u ) Q T − u ( y , x ) ,
with diagonals making the columns sum to zero, according to our convention. We observe that both are measurable in u u u . Moreover, it holds that
∫ 0 τ max x , y ( ∣ Q ~ u ∣ + ∣ Q ^ u ∣ ) d u < ∞ , \int_0^\tau\max_{x,y}(|\widetilde{Q}_u|+|\widehat{Q}_u|)\,du<\infty, ∫ 0 τ x , y max ( ∣ Q u ∣ + ∣ Q u ∣ ) d u < ∞ ,
in fact ∣ Q ^ u ( x , y ) ∣ ≤ sup s ⋅ σ T − u max ∣ Q 0 ∣ |\widehat{Q}_u(x,y)|\leq\sup s\cdot\sigma_{T-u}\max|Q_0| ∣ Q u ( x , y ) ∣ ≤ sup s ⋅ σ T − u max ∣ Q 0 ∣ , and s ⋆ s^\star s ⋆ is bounded on [ T 0 , T ] [T_0,T] [ T 0 , T ] : the latter follows in the masked case because s ⋆ ≤ κ t ≤ κ T 0 s^\star\leq\kappa_t\leq\kappa_{T_0} s ⋆ ≤ κ t ≤ κ T 0 by Proposition 2, and in the uniform case by Lemma 9, with ∫ 0 T σ < ∞ \int_0^T\sigma<\infty ∫ 0 T σ < ∞ .
Call now p u : = μ T − u p_u:=\mu_{T-u} p u := μ T − u and q u : = ν u q_u:=\nu_u q u := ν u . By definition q q q is the absolutely continuous solution of ∂ u q u = Q ^ u q u \partial_uq_u=\widehat{Q}_uq_u ∂ u q u = Q u q u , q 0 = μ ∞ > 0 q_0=\mu_\infty>0 q 0 = μ ∞ > 0 . We claim that ∂ u p u = Q ~ u p u \partial_up_u=\widetilde{Q}_up_u ∂ u p u = Q u p u for a.e. u u u , with p 0 = μ T p_0=\mu_T p 0 = μ T . In order to prove it, for x ∈ X x\in\mathcal{X} x ∈ X , we have that
( Q ~ u μ T − u ) ( x ) = ∑ y ≠ x s ⋆ ( x , y , T − u ) Q T − u ( y , x ) μ T − u ( y ) − μ T − u ( x ) ∑ y ≠ x s ⋆ ( y , x , T − u ) Q T − u ( x , y ) . (\widetilde{Q}_u\mu_{T-u})(x)=\sum_{y\ne x}s^\star(x,y,T-u)Q_{T-u}(y,x)\mu_{T-u}(y)-\mu_{T-u}(x)\sum_{y\ne x}s^\star(y,x,T-u)Q_{T-u}(x,y). ( Q u μ T − u ) ( x ) = y = x ∑ s ⋆ ( x , y , T − u ) Q T − u ( y , x ) μ T − u ( y ) − μ T − u ( x ) y = x ∑ s ⋆ ( y , x , T − u ) Q T − u ( x , y ) .
Whenever Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 one has s ⋆ ( x , y , t ) μ t ( y ) = μ t ( x ) s^\star(x,y,t)\mu_t(y)=\mu_t(x) s ⋆ ( x , y , t ) μ t ( y ) = μ t ( x ) : then, if μ t ( y ) > 0 \mu_t(y)>0 μ t ( y ) > 0 this is (4); otherwise, if μ t ( y ) = 0 \mu_t(y)=0 μ t ( y ) = 0 then s ⋆ = 0 s^\star=0 s ⋆ = 0 and also μ t ( x ) = 0 \mu_t(x)=0 μ t ( x ) = 0 . Let us notice that for the uniform kernel μ t > 0 \mu_t>0 μ t > 0 , so this case does not occur; on the other hand, in the masked case, Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 means y y y is obtained from x x x by masking one coordinate, so A ( y ) ⊆ A ( x ) A(y)\subseteq A(x) A ( y ) ⊆ A ( x ) and μ ( X A ( y ) = y A ( y ) ) = 0 \mu(X_{A(y)}=y_{A(y)})=0 μ ( X A ( y ) = y A ( y ) ) = 0 forces μ ( X A ( x ) = x A ( x ) ) = 0 \mu(X_{A(x)}=x_{A(x)})=0 μ ( X A ( x ) = x A ( x ) ) = 0 ). Applying this to both sums,
( Q ~ u μ T − u ) ( x ) = μ T − u ( x ) ∑ y ≠ x Q T − u ( y , x ) − ∑ y ≠ x Q T − u ( x , y ) μ T − u ( y ) = − ( Q T − u μ T − u ) ( x ) = d d u μ T − u ( x ) , \begin{aligned}
(\widetilde{Q}_u\mu_{T-u})(x)=\mu_{T-u}(x)\sum_{y\ne x}Q_{T-u}(y,x)-\sum_{y\ne x}Q_{T-u}(x,y)\mu_{T-u}(y) \\
&=-(Q_{T-u}\mu_{T-u})(x) \\
&=\frac{d}{du}\mu_{T-u}(x),
\end{aligned} ( Q u μ T − u ) ( x ) = μ T − u ( x ) y = x ∑ Q T − u ( y , x ) − y = x ∑ Q T − u ( x , y ) μ T − u ( y ) = − ( Q T − u μ T − u ) ( x ) = d u d μ T − u ( x ) ,
by the column convention and (3). This is the time-reversal property behind (5). Now, the support of p u = μ T − u p_u=\mu_{T-u} p u = μ T − u does not depend on u ∈ [ 0 , τ ] u\in[0,\tau] u ∈ [ 0 , τ ] by Lemma 7, applied to ρ = μ d a t a \rho=\mu_{\mathrm{data}} ρ = μ data on [ T 0 , T ] [T_0,T] [ T 0 , T ] , and q 0 > 0 q_0>0 q 0 > 0 . Moreover Q ^ u ( x , y ) > 0 \widehat{Q}_u(x,y)>0 Q u ( x , y ) > 0 whenever Q ~ u ( x , y ) > 0 \widetilde{Q}_u(x,y)>0 Q u ( x , y ) > 0 by the hypothesis on s s s , so D ( Q ~ u ( x , y ) , Q ^ u ( x , y ) ) < ∞ D(\widetilde{Q}_u(x,y),\widehat{Q}_u(x,y))<\infty D ( Q u ( x , y ) , Q u ( x , y )) < ∞ for every pair. Integrating (31) over [ 0 , τ ] [0,\tau] [ 0 , τ ] ,
KL ( μ T 0 ∥ ν τ ) = KL ( p τ ∥ q τ ) ≤ KL ( p 0 ∥ q 0 ) + ∫ 0 τ ∑ y μ T − u ( y ) ∑ x ≠ y D ( Q ~ u ( x , y ) , Q ^ u ( x , y ) ) d u . \operatorname{KL}(\mu_{T_0}\mathbin\Vert\nu_\tau)=\operatorname{KL}(p_\tau\mathbin\Vert q_\tau)\leq\operatorname{KL}(p_0\mathbin\Vert q_0)+\int_0^\tau\sum_y\mu_{T-u}(y)\sum_{x\ne y}D(\widetilde{Q}_u(x,y),\widehat{Q}_u(x,y))\,\mathrm{d}u. KL ( μ T 0 ∥ ν τ ) = KL ( p τ ∥ q τ ) ≤ KL ( p 0 ∥ q 0 ) + ∫ 0 τ y ∑ μ T − u ( y ) x = y ∑ D ( Q u ( x , y ) , Q u ( x , y )) d u .
Since by homogeneity D ( c a , c b ) = c D ( a , b ) D(ca,cb)=cD(a,b) D ( c a , c b ) = cD ( a , b ) for c > 0 c>0 c > 0 , with D ( 0 , 0 ) = 0 D(0,0)=0 D ( 0 , 0 ) = 0 . Taking c = Q T − u ( y , x ) c=Q_{T-u}(y,x) c = Q T − u ( y , x ) the inner sum equals ∑ x ≠ y Q T − u ( y , x ) D ( s ∗ ( x , y , T − u ) , s ( x , y , T − u ) ) \sum_{x\ne y}Q_{T-u}(y,x)D(s^*(x,y,T-u),s(x,y,T-u)) ∑ x = y Q T − u ( y , x ) D ( s ∗ ( x , y , T − u ) , s ( x , y , T − u )) , and the substitution t = T − u t=T-u t = T − u turns the integral into ∫ T 0 T E t ( s ) d t \int_{T_0}^{T}\mathcal{E}_t(s)\mathrm{d}t ∫ T 0 T E t ( s ) d t . This is (42).
Proof of Theorem 1
We want to prove in this subsection Theorem 1. In order to do that, we are going to prove some key lemmas before, and also we are going to need the following results.
Lemma 12 ([12 ] , Section 6.1, Lemma 3). Let P ^ n = ( p ^ j ) j \widehat{P}_n=(\widehat{p}_j)_j P n = ( p j ) j with p ^ j = N j + λ n + λ K d \widehat{p}_j=\frac{N_j+\lambda}{n+\lambda K^d} p j = n + λ K d N j + λ for some λ ∈ ( 0 , n / K d ] \lambda\in(0,n/K^d] λ ∈ ( 0 , n / K d ] that may depend on X 1 , … , X n X_1,\ldots,X_n X 1 , … , X n , and let p ‾ j : = N j / n \overline{p}_j:=N_j/n p j := N j / n be the empirical frequencies. Then
KL ( P ∥ P ^ n ) ≤ 6 ∑ j ( p ‾ j − p j ) 2 + 7 λ K d n + ∑ j : p j ≥ 4 λ / n p j log ( 2 n p j λ ) 1 ( N j ≤ n p j 4 ) . \operatorname{KL}(P\mathbin\Vert\widehat{P}_n)\leq6\sum_j\left(\sqrt{\overline{p}_j}-\sqrt{p_j}\right)^2+\frac{7\lambda K^d}{n}+\sum_{j:p_j\geq4\lambda/n}p_j\log\left(\frac{2np_j}{\lambda}\right)\mathbf{1}\left(N_j\leq\frac{np_j}{4}\right). KL ( P ∥ P n ) ≤ 6 j ∑ ( p j − p j ) 2 + n 7 λ K d + j : p j ≥ 4 λ / n ∑ p j log ( λ 2 n p j ) 1 ( N j ≤ 4 n p j ) .
Lemma 13 ([12 ] , Lemma 4). We use the same notation as Lemma 12. For n , K d ≥ 2 n,K^d\geq2 n , K d ≥ 2 , and δ ∈ ( 0 , 1 ) \delta\in(0,1) δ ∈ ( 0 , 1 ) , with probability at least 1 − 2 δ 1-2\delta 1 − 2 δ ,
∑ j ∈ X 0 ( p ‾ j − p j ) 2 ≤ 4 k e f f ( μ d a t a , n ) + 7 log 1 δ n . (44) \sum_{j\in\mathcal{X}_0}\left(\sqrt{\overline{p}_j}-\sqrt{p_j}\right)^2\leq\frac{4k_{\mathrm{eff}}(\mu_{\mathrm{data}},n)+7\log\frac{1}{\delta}}{n}. \tag*{(44)} j ∈ X 0 ∑ ( p j − p j ) 2 ≤ n 4 k eff ( μ data , n ) + 7 log δ 1 . (44)
Lemma 14 ([12 ] , Lemma 5). In the same setting as Lemma 12, for n ≥ 12 n\geq12 n ≥ 12 , λ = 1 \lambda=1 λ = 1 , K d ≥ 2 K^d\geq2 K d ≥ 2 and δ ∈ ( e − n / 6 , e − 2 ) \delta\in(e^{-n/6},e^{-2}) δ ∈ ( e − n /6 , e − 2 ) , with probability at least 1 − 2 δ 1-2\delta 1 − 2 δ ,
R λ : = ∑ j : p j ≥ 4 λ / n p j log ( 2 n p j λ ) 1 ( N j ≤ n p j 4 ) ≤ 62000 ∣ { x : p ( x ) ≥ 4 / n } ∣ + 106000 log 1 δ log log 1 δ n . (45) R_\lambda:=\sum_{j:p_j\geq4\lambda/n}p_j\log\left(\frac{2np_j}{\lambda}\right)\mathbf{1}\left(N_j\leq\frac{np_j}{4}\right)\leq\frac{62000|\{x:p(x)\geq4/n\}|+106000\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}. \tag*{(45)} R λ := j : p j ≥ 4 λ / n ∑ p j log ( λ 2 n p j ) 1 ( N j ≤ 4 n p j ) ≤ n 62000∣ { x : p ( x ) ≥ 4/ n } ∣ + 106000 log δ 1 log log δ 1 . (45)
Lemma 15 ([12 ] , Theorem 6). In the same setting as Lemma 12, let
U n : = ∑ x p ( x ) 1 ( N x ≤ n p ( x ) / 4 ) . (46) U_n:=\sum_xp(x)\mathbf{1}\left(N_x\leq np(x)/4\right). \tag*{(46)} U n := x ∑ p ( x ) 1 ( N x ≤ n p ( x ) /4 ) . (46) For n , K d ≥ 2 n,K^d\geq2 n , K d ≥ 2 and δ ∈ ( 0 , e − 1 ) \delta\in(0,e^{-1}) δ ∈ ( 0 , e − 1 ) , with probability at least 1 − 8 δ 1-8\delta 1 − 8 δ
U n ≤ 336 k e f f ( μ d a t a , n / 112 ) + 2500 e log 1 δ n . (47) U_n\leq\frac{336k_{\mathrm{eff}}(\mu_{\mathrm{data}},n/112)+2500e\log\frac{1}{\delta}}{n}. \tag*{(47)} U n ≤ n 336 k eff ( μ data , n /112 ) + 2500 e log δ 1 . (47)
We define and recall now some objects that are going to be useful for the proof of the theorem. Given our sample S = ( X 0 ( 1 ) , … , X 0 ( n ) ) S=(X_0^{(1)},\ldots,X_0^{(n)}) S = ( X 0 ( 1 ) , … , X 0 ( n ) ) , we call μ 0 ( n ) : = 1 n ∑ i δ X 0 ( i ) \mu_0^{(n)}:=\frac{1}{n}\sum_i\delta_{X_0^{(i)}} μ 0 ( n ) := n 1 ∑ i δ X 0 ( i ) and a x : = n μ d a t a ( x ) a_x:=n\mu_{\mathrm{data}}(x) a x := n μ data ( x ) . For γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] we set L γ : = log ( e K d / γ ) ≥ 1 L_\gamma:=\log(eK^d/\gamma)\geq1 L γ := log ( e K d / γ ) ≥ 1 and denote by μ ^ 0 ( γ ) \widehat{\mu}_0^{(\gamma)} μ 0 ( γ ) the estimator (1) with parameter γ \gamma γ ,
μ ^ 0 ( γ ) ( x ) = N 0 ( x ) + γ / K d n + γ , x ∈ X 0 . \widehat{\mu}_0^{(\gamma)}(x)=\frac{N_0(x)+\gamma/K^d}{n+\gamma},\qquad x\in\mathcal{X}_0. μ 0 ( γ ) ( x ) = n + γ N 0 ( x ) + γ / K d , x ∈ X 0 .
The parameter γ \gamma γ is a measurable map γ : X 0 n → [ 1 , min { n , K d } ] \gamma:\mathcal{X}_0^n \to[1,\min\{n,K^d\}] γ : X 0 n → [ 1 , min { n , K d }] , and μ ^ 0 : = μ ^ 0 ( γ ( S ) ) \hat{\mu}_0 := \hat{\mu}_0^{(\gamma(S))} μ ^ 0 := μ ^ 0 ( γ ( S )) . A deterministic γ \gamma γ is the special case of a constant map. Finally we define three quantities dependent on the sample, but not on the parameter
H n : = ∑ x ( μ 0 ( n ) ( x ) − μ d a t a ( x ) ) 2 , U n : = ∑ x μ d a t a ( x ) 1 ( N 0 ( x ) ≤ a x / 4 ) , H_n := \sum_x \left(\sqrt{\mu_0^{(n)}(x)}-\sqrt{\mu_{\mathrm{data}}(x)}\right)^2,\qquad U_n := \sum_x \mu_{\mathrm{data}}(x)\mathbf{1}(N_0(x)\le a_x/4), H n := x ∑ ( μ 0 ( n ) ( x ) − μ data ( x ) ) 2 , U n := x ∑ μ data ( x ) 1 ( N 0 ( x ) ≤ a x /4 ) ,
V n : = ∑ x : a x ≥ 1 / 2 μ d a t a ( x ) log ( 2 a x ) 1 ( N 0 ( x ) ≤ a x / 4 ) . V_n := \sum_{x:a_x\ge1/2}\mu_{\mathrm{data}}(x)\log(2a_x)\mathbf{1}(N_0(x)\le a_x/4). V n := x : a x ≥ 1/2 ∑ μ data ( x ) log ( 2 a x ) 1 ( N 0 ( x ) ≤ a x /4 ) .
They do not depend on γ \gamma γ and are nonnegative, since log ( 2 a x ) ≥ 0 \log(2a_x)\ge0 log ( 2 a x ) ≥ 0 on the range of V n V_n V n . We observe that above U n U_n U n is the mass of the classes that empirically are observed less that one forth of the their true frequency.
We prove now Lemma 2.
Proof of Lemma 2. To start, we notice that, thanks to Lemma 12 we can immediately bound our object. In order to do that, we fix a sample S S S and a γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] . Taking λ = γ / K d \lambda=\gamma/K^d λ = γ / K d and p ^ = μ ^ 0 ( γ ) \hat{p}=\hat{\mu}_0^{(\gamma)} p ^ = μ ^ 0 ( γ ) , we have that
KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) ≤ 6 H n + 7 γ n + R γ , (48) \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)})\le6H_n+\frac{7\gamma}{n}+R_\gamma, \tag*{(48)} KL ( μ data ∣ μ ^ 0 ( γ ) ) ≤ 6 H n + n 7 γ + R γ , (48)
where
R γ : = ∑ x : a x ≥ 4 γ / K d μ d a t a ( x ) log 2 a x K d γ 1 ( N 0 ( x ) ≤ a x / 4 ) . R_\gamma:=\sum_{x:a_x\ge4\gamma/K^d}\mu_{\mathrm{data}}(x)\log\frac{2a_xK^d}{\gamma}\mathbf{1}(N_0(x)\le a_x/4). R γ := x : a x ≥ 4 γ / K d ∑ μ data ( x ) log γ 2 a x K d 1 ( N 0 ( x ) ≤ a x /4 ) .
Moreover, we can rewrite the logarithm as log ( 2 a x ) + log K d γ \log(2a_x)+\log\frac{K^d}{\gamma} log ( 2 a x ) + log γ K d . Then, R γ ≤ log K d γ U n + V n R_\gamma\le\log\frac{K^d}{\gamma}U_n+V_n R γ ≤ log γ K d U n + V n , where log K d γ ≥ 0 \log\frac{K^d}{\gamma}\ge0 log γ K d ≥ 0 because γ ≤ K d \gamma\le K^d γ ≤ K d by assumption. We notice that above the range of the sums changed: in fact, in the case of V n V_n V n it includes only the terms for which log ( 2 a x ) ≥ 0 \log(2a_x)\ge0 log ( 2 a x ) ≥ 0 , i.e. a x ≥ 1 / 2 a_x\ge1/2 a x ≥ 1/2 , because the others are negative; in the other hand, the range in the case of U n U_n U n is the whole X 0 \mathcal{X}_0 X 0 , so we are adding more positive terms. We then arrive to the following upper bound
KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) ≤ 6 H n + 7 γ n + V n + log K d γ U n , (49) \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)})\le6H_n+\frac{7\gamma}{n}+V_n+\log\frac{K^d}{\gamma}U_n, \tag*{(49)} KL ( μ data ∣ μ ^ 0 ( γ ) ) ≤ 6 H n + n 7 γ + V n + log γ K d U n , (49)
where H n , V n , U n H_n,V_n,U_n H n , V n , U n do not depend on γ \gamma γ .
We control now these three terms in expectation. To begin, we observe that when μ d a t a ( x ) = 0 \mu_{\mathrm{data}}(x)=0 μ data ( x ) = 0 then p ˉ ( x ) = 0 \bar{p}(x)=0 p ˉ ( x ) = 0 , so those x x x are negligible. For x x x such that μ d a t a ( x ) > 0 \mu_{\mathrm{data}}(x)>0 μ data ( x ) > 0 , we use that ( a − b ) 2 = ( a − b ) 2 ( a + b ) 2 ≤ ( a − b ) 2 b \left(\sqrt{a}-\sqrt{b}\right)^2=\frac{(a-b)^2}{(\sqrt{a}+\sqrt{b})^2}\le\frac{(a-b)^2}{b} ( a − b ) 2 = ( a + b ) 2 ( a − b ) 2 ≤ b ( a − b ) 2 and that ( a − b ) 2 ≤ a + b \left(\sqrt{a}-\sqrt{b}\right)^2\le a+b ( a − b ) 2 ≤ a + b . Moreover, E S μ 0 ( n ) ( x ) = μ d a t a ( x ) \mathbb{E}_S\mu_0^{(n)}(x)=\mu_{\mathrm{data}}(x) E S μ 0 ( n ) ( x ) = μ data ( x ) and, since our sample is i.i.d, E ( μ 0 ( n ) ( x ) − μ d a t a ( x ) ) 2 = μ d a t a ( x ) ( 1 − μ d a t a ( x ) ) / n \mathbb{E}(\mu_0^{(n)}(x)-\mu_{\mathrm{data}}(x))^2=\mu_{\mathrm{data}}(x)(1-\mu_{\mathrm{data}}(x))/n E ( μ 0 ( n ) ( x ) − μ data ( x ) ) 2 = μ data ( x ) ( 1 − μ data ( x )) / n , thus
E S ( 6 H n ) ≤ 6 ∑ x min { 1 n , 2 μ d a t a } ≤ ∑ x 12 n min { 1 , a x } = 12 k e f f n . (50) \mathbb{E}_S(6H_n)\le6\sum_x\min\left\{\frac{1}{n},2\mu_{\mathrm{data}}\right\}\le\sum_x\frac{12}{n}\min\{1,a_x\}=\frac{12k_{\mathrm{eff}}}{n}. \tag*{(50)} E S ( 6 H n ) ≤ 6 x ∑ min { n 1 , 2 μ data } ≤ x ∑ n 12 min { 1 , a x } = n 12 k eff . (50)
Using again the fact that our sample is i.i.d, we observe immediately that N 0 ( x ) ∼ Bin ( n , μ d a t a ( x ) ) N_0(x)\sim\operatorname{Bin}(n,\mu_{\mathrm{data}}(x)) N 0 ( x ) ∼ Bin ( n , μ data ( x )) . Thanks to the multiplicative Chernoff bound, P ( N 0 ( x ) ≤ ( 1 − θ ) n μ d a t a ( x ) ) ≤ e − θ 2 n μ d a t a ( x ) / 2 \mathbb{P}(N_0(x)\le(1-\theta)n\mu_{\mathrm{data}}(x))\le e^{-\theta^2n\mu_{\mathrm{data}}(x)/2} P ( N 0 ( x ) ≤ ( 1 − θ ) n μ data ( x )) ≤ e − θ 2 n μ data ( x ) /2 , so in particular P ( N 0 ( x ) ≤ a x / 4 ) ≤ e − 9 n μ d a t a ( x ) / 32 \mathbb{P}(N_0(x)\le a_x/4)\le e^{-9n\mu_{\mathrm{data}}(x)/32} P ( N 0 ( x ) ≤ a x /4 ) ≤ e − 9 n μ data ( x ) /32 , where we took θ = 3 4 \theta=\frac{3}{4} θ = 4 3 . Hence,
E S U n ≤ 1 n ∑ x a x e − 9 a x / 32 and E S V n ≤ 1 n ∑ x : a x ≥ 1 / 2 a x log ( 2 a x ) e − 9 a x / 32 . (51) \mathbb{E}_S U_n\le\frac{1}{n}\sum_x a_xe^{-9a_x/32}
\qquad\text{and}\qquad
\mathbb{E}_S V_n\le\frac{1}{n}\sum_{x:a_x\ge1/2}a_x\log(2a_x)e^{-9a_x/32}. \tag*{(51)} E S U n ≤ n 1 x ∑ a x e − 9 a x /32 and E S V n ≤ n 1 x : a x ≥ 1/2 ∑ a x log ( 2 a x ) e − 9 a x /32 . (51)
We split the analysis of the terms inside the sums into two cases. If a x ≤ 8 a_x \le8 a x ≤ 8 , then a x e − 9 a x / 32 ≤ a x a_x e^{-9a_x/32} \le a_x a x e − 9 a x /32 ≤ a x , since the exponent is negative, and a x log ( 2 a x ) e − 9 a x / 32 ≤ a x log ( 16 ) a_x \log(2a_x)e^{-9a_x/32} \le a_x\log(16) a x log ( 2 a x ) e − 9 a x /32 ≤ a x log ( 16 ) . On the other hand, if a x ≥ 8 a_x \ge8 a x ≥ 8 ,
a x e − 9 a x / 32 = a x e − 5 a x / 32 e − a x / 8 ≤ e − a x / 8 sup a x > 0 ( a x e − 5 a x / 32 ) = e − a x / 8 32 5 e ≤ e − a x / 8 e ≤ e 1 − a x / 8 . \begin{aligned}
a_x e^{-9a_x/32}=a_x e^{-5a_x/32}e^{-a_x/8} \\
&\le e^{-a_x/8}\sup_{a_x>0}\left(a_xe^{-5a_x/32}\right) \\
&=e^{-a_x/8}\frac{32}{5e} \\
&\le e^{-a_x/8}e \\
&\le e^{1-a_x/8}.
\end{aligned} a x e − 9 a x /32 = a x e − 5 a x /32 e − a x /8 ≤ e − a x /8 a x > 0 sup ( a x e − 5 a x /32 ) = e − a x /8 5 e 32 ≤ e − a x /8 e ≤ e 1 − a x /8 .
Moreover,
a x log ( 2 a x ) e − 9 a x / 32 ≤ 2 a x 3 / 2 e − 5 a x / 32 e − a x / 8 ≤ 2 e − a x / 8 sup a > 0 a 3 / 2 e − 5 a / 32 = 2 ( 48 5 e ) 3 / 2 e − a x / 8 \begin{aligned}
a_x\log(2a_x)e^{-9a_x/32}\le\sqrt{2}a_x^{3/2}e^{-5a_x/32}e^{-a_x/8} \\
&\le\sqrt{2}e^{-a_x/8}\sup_{a>0}a^{3/2}e^{-5a/32} \\
&=\sqrt{2}\left(\frac{48}{5e}\right)^{3/2}e^{-a_x/8}
\end{aligned} a x log ( 2 a x ) e − 9 a x /32 ≤ 2 a x 3/2 e − 5 a x /32 e − a x /8 ≤ 2 e − a x /8 a > 0 sup a 3/2 e − 5 a /32 = 2 ( 5 e 48 ) 3/2 e − a x /8
≤ 4 e 1 − a x / 8 , \le4e^{1-a_x/8}, ≤ 4 e 1 − a x /8 ,
where above we used that log u ≤ u \log u\le\sqrt{u} log u ≤ u for u > 0 u>0 u > 0 and sup a > 0 a p e − c a = ( p c e ) p \sup_{a>0}a^pe^{-ca}=\left(\frac{p}{ce}\right)^p sup a > 0 a p e − c a = ( ce p ) p . If we call m ( a ) : = min { e 1 − a / 8 , a / 8 } m(a):=\min\{e^{1-a/8},a/8\} m ( a ) := min { e 1 − a /8 , a /8 } , we notice that we gave as upper bound always a multiple of m ( a x ) m(a_x) m ( a x ) . Noticing that ∑ x m ( a x ) = k e f f ∘ ( μ d a t a , n / 8 ) \sum_xm(a_x)=k_{\mathrm{eff}}^{\circ}(\mu_{\mathrm{data}},n/8) ∑ x m ( a x ) = k eff ∘ ( μ data , n /8 ) , we get
E S U n ≤ 8 k e f f ∘ ( μ d a t a , n / 8 ) n and E S V n ≤ 23 k e f f ∘ ( μ d a t a , n / 8 ) n . (52) \mathbb{E}_S U_n\le\frac{8k_{\mathrm{eff}}^{\circ}(\mu_{\mathrm{data}},n/8)}{n}
\qquad\text{and}\qquad
\mathbb{E}_S V_n\le\frac{23k_{\mathrm{eff}}^{\circ}(\mu_{\mathrm{data}},n/8)}{n}. \tag*{(52)} E S U n ≤ n 8 k eff ∘ ( μ data , n /8 ) and E S V n ≤ n 23 k eff ∘ ( μ data , n /8 ) . (52)
We can now finish the proof. We just need to control the term log K d γ U n \log\frac{K^d}{\gamma}U_n log γ K d U n . We notice first of all that, since γ \gamma γ depends on S S S and the function γ ↦ log K d γ \gamma\mapsto\log\frac{K^d}{\gamma} γ ↦ log γ K d is decreasing in [ γ 0 , K d ] [\gamma_0,K^d] [ γ 0 , K d ] , we have that if γ ≥ γ 0 \gamma\ge\gamma_0 γ ≥ γ 0 , log K d γ ≤ log K d γ 0 ≤ log e K d γ 0 = L γ 0 \log\frac{K^d}{\gamma}\le\log\frac{K^d}{\gamma_0}\le\log\frac{eK^d}{\gamma_0}=L_{\gamma_0} log γ K d ≤ log γ 0 K d ≤ log γ 0 e K d = L γ 0 . On the other hand, if γ < γ 0 \gamma<\gamma_0 γ < γ 0 , then
log K d γ = log K d γ 0 + log γ 0 γ ≤ log K d γ 0 + log γ 0 ≤ log e K d γ 0 + log γ 0 = L γ 0 + log γ 0 , \begin{aligned}
\log\frac{K^d}{\gamma}=\log\frac{K^d}{\gamma_0}+\log\frac{\gamma_0}{\gamma} \\
&\le\log\frac{K^d}{\gamma_0}+\log\gamma_0 \\
&\le\log\frac{eK^d}{\gamma_0}+\log\gamma_0 \\
&=L_{\gamma_0}+\log\gamma_0,
\end{aligned} log γ K d = log γ 0 K d + log γ γ 0 ≤ log γ 0 K d + log γ 0 ≤ log γ 0 e K d + log γ 0 = L γ 0 + log γ 0 ,
where we used that γ ≥ 1 \gamma\ge1 γ ≥ 1 . Then, to write both cases in a compact notation,
log K d γ ≤ L γ 0 + log γ 0 1 ( γ < γ 0 ) . (53) \log\frac{K^d}{\gamma}\le L_{\gamma_0}+\log\gamma_0 1(\gamma<\gamma_0). \tag*{(53)} log γ K d ≤ L γ 0 + log γ 0 1 ( γ < γ 0 ) . (53)
Then, using 0 ≤ U n ≤ 1 0\le U_n\le1 0 ≤ U n ≤ 1
E S [ log K d γ U n ] ≤ L γ 0 E S U n + log γ 0 P ( γ < γ 0 ) . (54) \mathbb{E}_S\left[\log\frac{K^d}{\gamma}U_n\right]\le L_{\gamma_0}\mathbb{E}_S U_n+\log\gamma_0\mathbb{P}(\gamma<\gamma_0). \tag*{(54)} E S [ log γ K d U n ] ≤ L γ 0 E S U n + log γ 0 P ( γ < γ 0 ) . (54)
Putting all the results above together, we conclude.
Proof of Lemma 3. To start, we recall the setting of the lemma above. Thanks to Lemma 12 we can immediately bound our object: fixing a sample S S S , a γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] , λ = γ / K d \lambda=\gamma/K^d λ = γ / K d , and p ^ = μ ^ 0 ( γ ) \widehat{p}=\widehat{\mu}_0^{(\gamma)} p = μ 0 ( γ ) , we have that
KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) ≤ 6 H n + 7 γ n + R γ , (55) \operatorname{KL}(\mu_{\mathrm{data}}\mid\widehat{\mu}_0^{(\gamma)})\le6H_n+\frac{7\gamma}{n}+R_\gamma, \tag*{(55)} KL ( μ data ∣ μ 0 ( γ ) ) ≤ 6 H n + n 7 γ + R γ , (55)
where
R γ : = ∑ x : a x ≥ 4 γ / K d μ d a t a ( x ) log 2 a x K d γ 1 ( N 0 ( x ) ≤ a x / 4 ) . R_\gamma:=\sum_{x:a_x\ge4\gamma/K^d}\mu_{\mathrm{data}}(x)\log\frac{2a_xK^d}{\gamma}\mathbb{1}(N_0(x)\le a_x/4). R γ := x : a x ≥ 4 γ / K d ∑ μ data ( x ) log γ 2 a x K d 1 ( N 0 ( x ) ≤ a x /4 ) .
Moreover, rewriting the logarithm, R γ ≤ log K d γ U n + V n R_\gamma\le\log\frac{K^d}{\gamma}U_n+V_n R γ ≤ log γ K d U n + V n , where log K d γ ≥ 0 \log\frac{K^d}{\gamma}\ge0 log γ K d ≥ 0 because γ ≤ K d \gamma\le K^d γ ≤ K d . We then arrive to
KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) ≤ 6 H n + 7 γ n + V n + log K d γ U n , \operatorname{KL}(\mu_{\mathrm{data}}\mid\widehat{\mu}_0^{(\gamma)})\le6H_n+\frac{7\gamma}{n}+V_n+\log\frac{K^d}{\gamma}U_n, KL ( μ data ∣ μ 0 ( γ ) ) ≤ 6 H n + n 7 γ + V n + log γ K d U n ,
where H n , V n , U n H_n,V_n,U_n H n , V n , U n do not depend on γ \gamma γ .
Let now A 1 A_1 A 1 , A 2 A_2 A 2 , A 3 A_3 A 3 be the events of Lemmas 13 , 14 and 15 (notice that the last one applies since δ < e − 2 < e − 1 \delta<e^{-2}<e^{-1} δ < e − 2 < e − 1 ), of probabilities at least 1 − 2 δ 1-2\delta 1 − 2 δ , 1 − 2 δ 1-2\delta 1 − 2 δ , 1 − 8 δ 1-8\delta 1 − 8 δ respectively; each is defined through S S S only. On A 1 A_1 A 1 ,
6 H n ≤ 24 k e f f + 42 log 1 δ n . (56) 6H_n\le\frac{24k_{\mathrm{eff}}+42\log\frac{1}{\delta}}{n}. \tag*{(56)} 6 H n ≤ n 24 k eff + 42 log δ 1 . (56)
For V n V_n V n , the terms with 1 2 ≤ a x < 4 \frac{1}{2}\le a_x<4 2 1 ≤ a x < 4 satisfy log ( 2 a x ) < log 8 \log(2a_x)<\log8 log ( 2 a x ) < log 8 and contribute at most
log 8 ∑ x : μ d a t a ( x ) < 4 / n μ d a t a ( x ) . \log8\sum_{x:\mu_{\mathrm{data}}(x)<4/n}\mu_{\mathrm{data}}(x). log 8 x : μ data ( x ) < 4/ n ∑ μ data ( x ) .
By the second expression of k e f f k_{\mathrm{eff}} k eff in Definition 1,
∑ x : μ d a t a ( x ) < 4 / n μ d a t a ( x ) ≤ 1 n [ ∑ x : μ d a t a ( x ) < 1 / n a x + 4 ∣ { x : μ d a t a ( x ) ≥ 1 n } ∣ ] ≤ 4 k e f f n ; \sum_{x:\mu_{\mathrm{data}}(x)<4/n}\mu_{\mathrm{data}}(x)\le\frac{1}{n}\left[\sum_{x:\mu_{\mathrm{data}}(x)<1/n}a_x+4\left|\left\{x:\mu_{\mathrm{data}}(x)\ge\frac{1}{n}\right\}\right|\right]\le\frac{4k_{\mathrm{eff}}}{n}; x : μ data ( x ) < 4/ n ∑ μ data ( x ) ≤ n 1 x : μ data ( x ) < 1/ n ∑ a x + 4 { x : μ data ( x ) ≥ n 1 } ≤ n 4 k eff ;
the terms with a x ≥ 4 a_x\ge4 a x ≥ 4 are exactly those of R K d R_{K^d} R K d . Hence V n ≤ 4 log 8 k e f f n + R K d V_n\le\frac{4\log8\,k_{\mathrm{eff}}}{n}+R_{K^d} V n ≤ n 4 l o g 8 k eff + R K d and, on A 2 A_2 A 2 , using ∣ { x : μ d a t a ( x ) ≥ 4 / n } ∣ ≤ k e f f \left|\left\{x:\mu_{\mathrm{data}}(x)\ge4/n\right\}\right|\le k_{\mathrm{eff}} ∣ { x : μ data ( x ) ≥ 4/ n } ∣ ≤ k eff and 4 log 8 ≤ 9 4\log8\le9 4 log 8 ≤ 9 ,
V n ≤ 62009 k e f f + 106000 log 1 δ log log 1 δ n . (57) V_n\le\frac{62009k_{\mathrm{eff}}+106000\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}. \tag*{(57)} V n ≤ n 62009 k eff + 106000 log δ 1 log log δ 1 . (57)
On A 3 A_3 A 3 ,
U n ≤ 336 k e f f o ( μ d a t a , n / 112 ) + 2500 e log 1 δ n (58) U_n\le\frac{336k_{\mathrm{eff}}^{\mathrm{o}}(\mu_{\mathrm{data}},n/112)+2500e\log\frac{1}{\delta}}{n} \tag*{(58)} U n ≤ n 336 k eff o ( μ data , n /112 ) + 2500 e log δ 1 (58)
with 2500 e ≤ 6796 2500e\le6796 2500 e ≤ 6796 .
To finish, let us set A : = A 1 ∩ A 2 ∩ A 3 A:=A_1\cap A_2\cap A_3 A := A 1 ∩ A 2 ∩ A 3 , so P ( A ) ≥ 1 − 12 δ \mathbb{P}(A)\ge1-12\delta P ( A ) ≥ 1 − 12 δ by the union bound. On A A A , for every γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] , insert the three bounds and log K d γ ≤ L γ \log\frac{K^d}{\gamma}\le L_\gamma log γ K d ≤ L γ into (49) :
KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) ≤ ( 24 + 62009 ) k e f f + 7 γ + 336 k e f f o ( μ d a t a , n / 112 ) L γ n + ( 42 + 6796 L γ ) log 1 δ + 106000 log 1 δ log log 1 δ n , \operatorname{KL}(\mu_{\mathrm{data}}\mid\widehat{\mu}_0^{(\gamma)})\le\frac{(24+62009)k_{\mathrm{eff}}+7\gamma+336k_{\mathrm{eff}}^{\mathrm{o}}(\mu_{\mathrm{data}},n/112)L_\gamma}{n}
+\frac{(42+6796L_\gamma)\log\frac{1}{\delta}+106000\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}, KL ( μ data ∣ μ 0 ( γ ) ) ≤ n ( 24 + 62009 ) k eff + 7 γ + 336 k eff o ( μ data , n /112 ) L γ + n ( 42 + 6796 L γ ) log δ 1 + 106000 log δ 1 log log δ 1 ,
which is the claim. The bound holds for all γ \gamma γ on the same event A A A , and A A A does not depend on the parameter; therefore, for any parameter γ \gamma γ , on A A A it holds.
Proof of Lemma 4. To simplify the notations, for y ∈ X y \in\mathcal{X} y ∈ X we write μ ^ 0 ( y A ( y ) ) : = μ ^ 0 ( γ ) ( X A ( y ) = y A ( y ) ) \widehat{\mu}_0(y_{A(y)}) := \widehat{\mu}^{(\gamma)}_0(X_{A(y)} = y_{A(y)}) μ 0 ( y A ( y ) ) := μ 0 ( γ ) ( X A ( y ) = y A ( y ) ) , with μ ^ 0 ( y ∅ ) : = 1 \widehat{\mu}_0(y_{\varnothing}) := 1 μ 0 ( y ∅ ) := 1 ; since μ ^ 0 ( γ ) > 0 \widehat{\mu}^{(\gamma)}_0 > 0 μ 0 ( γ ) > 0 on X 0 \mathcal{X}_0 X 0 , μ ^ 0 ( y A ( y ) ) > 0 \widehat{\mu}_0(y_{A(y)}) > 0 μ 0 ( y A ( y ) ) > 0 for every y y y . Using the product form of P 0 , t m a s k P^{\mathrm{mask}}_{0,t} P 0 , t mask ,
μ ^ t ( y ) = α t ∣ A ( y ) ∣ ( 1 − α t ) d − ∣ A ( y ) ∣ μ ^ 0 ( y A ( y ) ) > 0 , t ∈ ( 0 , T ] . \widehat{\mu}_t(y) = \alpha_t^{|A(y)|}(1-\alpha_t)^{d-|A(y)|}\widehat{\mu}_0(y_{A(y)}) > 0,\qquad t \in(0,T]. μ t ( y ) = α t ∣ A ( y ) ∣ ( 1 − α t ) d − ∣ A ( y ) ∣ μ 0 ( y A ( y ) ) > 0 , t ∈ ( 0 , T ] .
Thus, we can rewrite the estimator of (15) for x , y x,y x , y such that Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 as
s ^ ( x , y , t ) = α t 1 − α t μ ^ 0 ( x A ( x ) ) μ ^ 0 ( y A ( y ) ) with x = ( y − i , x i ) , i ∈ M ( y ) . (59) \widehat{s}(x,y,t)=\frac{\alpha_t}{1-\alpha_t}\frac{\widehat{\mu}_0(x_{A(x)})}{\widehat{\mu}_0(y_{A(y)})}\qquad\text{with}\qquad x=(y_{-i},x_i),\ i\in M(y). \tag*{(59)} s ( x , y , t ) = 1 − α t α t μ 0 ( y A ( y ) ) μ 0 ( x A ( x ) ) with x = ( y − i , x i ) , i ∈ M ( y ) . (59)
We observe now that Q ^ u \widehat{Q}_u Q u explodes when u → T u\to T u → T since κ T − u → ∞ \kappa_{T-u}\to\infty κ T − u → ∞ and that is why we take the limit and we can not work on [ 0 , T ] [0,T] [ 0 , T ] . Also, recall that, for x ≠ y x\ne y x = y ,
Q ^ u ( y , x ) = s ^ ( y , x , T − u ) Q T − u ( x , y ) , \widehat{Q}_u(y,x)=\widehat{s}(y,x,T-u)Q_{T-u}(x,y), Q u ( y , x ) = s ( y , x , T − u ) Q T − u ( x , y ) ,
where Q T − u ( x , y ) Q_{T-u}(x,y) Q T − u ( x , y ) is the forward rate from y y y to x x x . Since the forward process only masks tokens, Q T − u ( x , y ) ≠ 0 Q_{T-u}(x,y)\ne0 Q T − u ( x , y ) = 0 if and only if x x x is obtained from y y y by masking one unmasked coordinate, that is, if and only if y = ( x − i , y i ) y=(x_{-i},y_i) y = ( x − i , y i ) for some i ∈ M ( x ) i\in M(x) i ∈ M ( x ) and y i ∈ V y_i\in\mathcal{V} y i ∈ V . In that case, Q T − u ( x , y ) = σ T − u Q_{T-u}(x,y)=\sigma_{T-u} Q T − u ( x , y ) = σ T − u . Therefore, for such pairs
Q ^ u ( y , x ) = σ T − u α T − u 1 − α T − u μ ^ 0 ( y A ( y ) ) μ ^ 0 ( x A ( x ) ) , (60) \widehat{Q}_u(y,x)=\frac{\sigma_{T-u}\alpha_{T-u}}{1-\alpha_{T-u}}\frac{\widehat{\mu}_0(y_{A(y)})}{\widehat{\mu}_0(x_{A(x)})}, \tag*{(60)} Q u ( y , x ) = 1 − α T − u σ T − u α T − u μ 0 ( x A ( x ) ) μ 0 ( y A ( y ) ) , (60)
and Q ^ u ( y , x ) = 0 \widehat{Q}_u(y,x)=0 Q u ( y , x ) = 0 for every other pair x ≠ y x\ne y x = y . For simplicity, we are going to denote from now on λ u : = σ T − u α T − u 1 − α T − u \lambda_u:=\frac{\sigma_{T-u}\alpha_{T-u}}{1-\alpha_{T-u}} λ u := 1 − α T − u σ T − u α T − u . Then, equation (6) reads
∂ u ν u ( y ) = ∑ x ≠ y Q ^ u ( y , x ) ν u ( x ) − ν u ( y ) ∑ x ≠ y Q ^ u ( x , y ) , with ν 0 = δ m d . (61) \partial_u\nu_u(y)=\sum_{x\ne y}\widehat{Q}_u(y,x)\nu_u(x)-\nu_u(y)\sum_{x\ne y}\widehat{Q}_u(x,y),\qquad\text{with}\qquad\nu_0=\delta_{m_d}. \tag*{(61)} ∂ u ν u ( y ) = x = y ∑ Q u ( y , x ) ν u ( x ) − ν u ( y ) x = y ∑ Q u ( x , y ) , with ν 0 = δ m d . (61)
Since for every T 0 T_0 T 0 such that 0 < T 0 < T 0<T_0<T 0 < T 0 < T and u ∈ [ 0 , T − T 0 ] u\in[0,T-T_0] u ∈ [ 0 , T − T 0 ] we have 0 ≤ λ u ≤ σ T − u 1 − α T 0 0\le\lambda_u\le\frac{\sigma_{T-u}}{1-\alpha_{T_0}} 0 ≤ λ u ≤ 1 − α T 0 σ T − u , that is integrable in u u u , we have that (61) is a linear system with locally integrable coefficients in [ 0 , T ) [0,T) [ 0 , T ) . By the Carathéodory existence and uniqueness theorem, since the system is linear with coefficients in L l o c 1 ( [ 0 , T ) ) L^1_{\mathrm{loc}}([0,T)) L loc 1 ([ 0 , T )) , it has a unique absolutely continuous solution ( ν u ) u ∈ [ 0 , T ) (\nu_u)_{u\in[0,T)} ( ν u ) u ∈ [ 0 , T ) . We want to write this solution explicitly.
Since u ∈ [ 0 , T ) u\in[0,T) u ∈ [ 0 , T ) , the map t ↦ log ( 1 − α t ) t\mapsto\log(1-\alpha_t) t ↦ log ( 1 − α t ) is absolutely continuous on [ T − u , T ] [T-u,T] [ T − u , T ] with derivative σ t α t 1 − α t \frac{\sigma_t\alpha_t}{1-\alpha_t} 1 − α t σ t α t a.e., so
Λ u : = ∫ 0 u λ z d z = ∫ T − u T σ t α t 1 − α t d t = log 1 − α T 1 − α T − u . (62) \Lambda_u:=\int_0^u\lambda_z\,\mathrm{d}z=\int_{T-u}^T\frac{\sigma_t\alpha_t}{1-\alpha_t}\,\mathrm{d}t=\log\frac{1-\alpha_T}{1-\alpha_{T-u}}. \tag*{(62)} Λ u := ∫ 0 u λ z d z = ∫ T − u T 1 − α t σ t α t d t = log 1 − α T − u 1 − α T . (62)
Moreover, we define
F u : = 1 − e − Λ u = α T − u − α T 1 − α T ∈ [ 0 , 1 ) . (63) F_u:=1-e^{-\Lambda_u}=\frac{\alpha_{T-u}-\alpha_T}{1-\alpha_T}\in[0,1). \tag*{(63)} F u := 1 − e − Λ u = 1 − α T α T − u − α T ∈ [ 0 , 1 ) . (63)
We focus on F F F . It is an absolutely continuous function on [ 0 , T ) [0,T) [ 0 , T ) with F 0 = 0 F_0=0 F 0 = 0 , F u → 1 F_u\to1 F u → 1 as u → T u\to T u → T due to the fact that α T − u → α 0 = 1 \alpha_{T-u}\to\alpha_0=1 α T − u → α 0 = 1 , and d d u F u = λ u ( 1 − F u ) \frac{\mathrm{d}}{\mathrm{d}u}F_u=\lambda_u(1-F_u) d u d F u = λ u ( 1 − F u ) . Thanks to F u F_u F u , we can define
ν ~ u ( y ) : = F u ∣ A ( y ) ∣ ( 1 − F u ) d − ∣ A ( y ) ∣ μ ^ 0 ( y A ( y ) ) , y ∈ X , u ∈ [ 0 , T ) . (64) \widetilde{\nu}_u(y):=F_u^{|A(y)|}(1-F_u)^{d-|A(y)|}\widehat{\mu}_0(y_{A(y)}),\qquad y\in\mathcal{X},\ u\in[0,T). \tag*{(64)} ν u ( y ) := F u ∣ A ( y ) ∣ ( 1 − F u ) d − ∣ A ( y ) ∣ μ 0 ( y A ( y ) ) , y ∈ X , u ∈ [ 0 , T ) . (64)
We assume the convention 0 0 = 1 0^0=1 0 0 = 1 . We claim that ν ~ u \widetilde{\nu}_u ν u is the explicit solution of (61) . First, we notice that the initial condition is δ m d \delta_{m_d} δ m d since F 0 = 0 F_0=0 F 0 = 0 makes ν ~ 0 ( y ) = 0 \widetilde{\nu}_0(y)=0 ν 0 ( y ) = 0 for all y y y such that A ( y ) ≠ ∅ A(y)\ne\varnothing A ( y ) = ∅ . Fix now y y y , k = ∣ A ( y ) ∣ k=|A(y)| k = ∣ A ( y ) ∣ and A : = A ( y ) A:=A(y) A := A ( y ) . By (61) , we can write
∑ x ≠ y Q ^ u ( x , y ) = λ u ∑ i ∈ M ( y ) ∑ a μ ^ 0 ( x A ∪ i ) μ ^ 0 ( y A ) = λ u ( d − k ) . \sum_{x\ne y}\widehat{Q}_u(x,y)=\lambda_u\sum_{i\in M(y)}\sum_a\frac{\widehat{\mu}_0(x_{A\cup i})}{\widehat{\mu}_0(y_A)}=\lambda_u(d-k). x = y ∑ Q u ( x , y ) = λ u i ∈ M ( y ) ∑ a ∑ μ 0 ( y A ) μ 0 ( x A ∪ i ) = λ u ( d − k ) .
Since the state x x x such that Q ^ u ( y , x ) ≠ 0 \widehat{Q}_u(y,x) \ne0 Q u ( y , x ) = 0 are exactly the ones that differs from y y y by only one token in a position i ∈ A i \in A i ∈ A , with a mask token in the case of x x x , thanks to (58) and the identity in (63), we have
Q ^ u ( y , x ) ν ~ u ( x ) = λ u μ ^ 0 ( y A ) μ ^ 0 ( y A ∖ i ) F u k − 1 ( 1 − F u ) d − k + 1 μ ^ 0 ( y A ∖ i ) = λ u F u k − 1 ( 1 − F u ) d − k + 1 μ ^ 0 ( y A ) . (65) \widehat{Q}_u(y,x)\widetilde{\nu}_u(x)=\lambda_u\frac{\widehat{\mu}_0(y_A)}{\widehat{\mu}_0(y_{A\setminus i})}F_u^{k-1}(1-F_u)^{d-k+1}\widehat{\mu}_0(y_{A\setminus i})=\lambda_uF_u^{k-1}(1-F_u)^{d-k+1}\widehat{\mu}_0(y_A). \tag*{(65)} Q u ( y , x ) ν u ( x ) = λ u μ 0 ( y A ∖ i ) μ 0 ( y A ) F u k − 1 ( 1 − F u ) d − k + 1 μ 0 ( y A ∖ i ) = λ u F u k − 1 ( 1 − F u ) d − k + 1 μ 0 ( y A ) . (65)
If we sum over i ∈ A i \in A i ∈ A , the right hand side of (60), at ν ~ u \widetilde{\nu}_u ν u is equal to
λ u μ ^ 0 ( y A ) [ k F u k − 1 ( 1 − F u ) d − k + 1 − ( d − k ) F u k ( 1 − F u ) d − k ] . \lambda_u\widehat{\mu}_0(y_A)\left[kF_u^{k-1}(1-F_u)^{d-k+1}-(d-k)F_u^k(1-F_u)^{d-k}\right]. λ u μ 0 ( y A ) [ k F u k − 1 ( 1 − F u ) d − k + 1 − ( d − k ) F u k ( 1 − F u ) d − k ] .
Furthermore, for a.e. u u u we also have that
d d u [ F u k ( 1 − F u ) d − k ] = [ k F u k − 1 ( 1 − F u ) d − k − ( d − k ) F u k ( 1 − F u ) d − k − 1 ] d d u F u = λ u [ k F u k − 1 ( 1 − F u ) d − k + 1 − ( d − k ) F u k ( 1 − F u ) d − k ] . \begin{aligned}
\frac{d}{du}\left[F_u^k(1-F_u)^{d-k}\right]=\left[kF_u^{k-1}(1-F_u)^{d-k}-(d-k)F_u^k(1-F_u)^{d-k-1}\right]\frac{d}{du}F_u \\
&=\lambda_u\left[kF_u^{k-1}(1-F_u)^{d-k+1}-(d-k)F_u^k(1-F_u)^{d-k}\right].
\end{aligned} d u d [ F u k ( 1 − F u ) d − k ] = [ k F u k − 1 ( 1 − F u ) d − k − ( d − k ) F u k ( 1 − F u ) d − k − 1 ] d u d F u = λ u [ k F u k − 1 ( 1 − F u ) d − k + 1 − ( d − k ) F u k ( 1 − F u ) d − k ] .
Above the terms with coefficient k = 0 k=0 k = 0 or d = k d=k d = k are absent. We can conclude then that the explicit solution for every u ∈ [ 0 , T ) u \in[0,T) u ∈ [ 0 , T ) is ν ~ u \widetilde{\nu}_u ν u .
To finish, for x ∈ X 0 x \in\mathcal{X}_0 x ∈ X 0 , we have that ν u ( x ) = F u d μ ^ 0 ( x ) → μ ^ 0 ( x ) \nu_u(x)=F_u^d\widehat{\mu}_0(x)\to\widehat{\mu}_0(x) ν u ( x ) = F u d μ 0 ( x ) → μ 0 ( x ) , by continuity, and for y ∉ X 0 y \notin\mathcal{X}_0 y ∈ / X 0 , 0 ≤ ν u ( y ) ≤ ( 1 − F u ) → 0 0\leq\nu_u(y)\leq(1-F_u)\to0 0 ≤ ν u ( y ) ≤ ( 1 − F u ) → 0 as u u u goes to T T T . Thus, defining ν ^ : = lim u → T ν u \widehat{\nu}:=\lim_{u\to T}\nu_u ν := lim u → T ν u , we have that the limit exists and it is equal to μ ^ 0 \widehat{\mu}_0 μ 0 .
We are now ready for the proof of Theorem 1.
Proof of Theorem 1. Fix a sample S S S . Then γ = γ ( S ) ∈ [ 1 , min { n , K d } ] \gamma=\gamma(S)\in[1,\min\{n,K^d\}] γ = γ ( S ) ∈ [ 1 , min { n , K d }] is a number, μ ^ 0 ( γ ( S ) ) \widehat{\mu}_0^{(\gamma(S))} μ 0 ( γ ( S )) is a strictly positive law on X 0 \mathcal{X}_0 X 0 , and s ^ \widehat{s} s of (15) is its score; Lemma 4 gives
KL ( μ d a t a ∥ ν ^ ) = KL ( μ d a t a ∥ μ ^ 0 ( γ ( S ) ) ) \operatorname{KL}(\mu_{\mathrm{data}}\Vert\widehat{\nu})=\operatorname{KL}(\mu_{\mathrm{data}}\Vert\widehat{\mu}_0^{(\gamma(S))}) KL ( μ data ∥ ν ) = KL ( μ data ∥ μ 0 ( γ ( S )) )
for this S S S . Then, the first item in the theorem’s statement follows by taking expectations and applying Lemma 2. Finally, the second item follows by intersecting with the event A A A of Lemma 3, which does not depend on γ \gamma γ .
Proofs of Section 3.3
Throughout this subsection we write k e f f : = k e f f ( μ d a t a , n ) k_{\mathrm{eff}}:=k_{\mathrm{eff}}(\mu_{\mathrm{data}},n) k eff := k eff ( μ data , n ) , L γ : = log e K d γ L_\gamma:=\log\frac{e^{K^d}}{\gamma} L γ := log γ e K d for γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] and Λ l : = L l = log e K d l \Lambda_l:=L_l=\log\frac{e^{K^d}}{l} Λ l := L l = log l e K d . We use repeatedly the elementary facts
k e f f e f f ( μ d a t a , m ) ≤ k e f f ( μ d a t a , m ) ≤ k e f f ≤ min { ∣ supp μ d a t a ∣ , K d } ( m ≤ n ) , (66) k_{\mathrm{eff}}^{\mathrm{eff}}(\mu_{\mathrm{data}},m)\leq k_{\mathrm{eff}}(\mu_{\mathrm{data}},m)\leq k_{\mathrm{eff}}\leq\min\{|\operatorname{supp}\mu_{\mathrm{data}}|,K^d\}\qquad(m\leq n), \tag*{(66)} k eff eff ( μ data , m ) ≤ k eff ( μ data , m ) ≤ k eff ≤ min { ∣ supp μ data ∣ , K d } ( m ≤ n ) , (66)
because min { e 1 − a , a } ≤ min { 1 , a } ≤ min { 1 , a ′ } \min\{e^{1-a},a\}\leq\min\{1,a\}\leq\min\{1,a'\} min { e 1 − a , a } ≤ min { 1 , a } ≤ min { 1 , a ′ } for 0 ≤ a ≤ a ′ 0\leq a\leq a' 0 ≤ a ≤ a ′ , and u ↦ u log e K d u u\mapsto u\log\frac{e^{K^d}}{u} u ↦ u log u e K d is nondecreasing on ( 0 , K d ] (0,K^d] ( 0 , K d ] because the derivative is log ( K d / u ) ≥ 0 \log(K^d/u)\geq0 log ( K d / u ) ≥ 0 .
We start now with an important lemma.
Lemma 16 (Distinct observed states). Let s n ′ : = E S [ D n ] s'_n:=\mathbb{E}_S[D_n] s n ′ := E S [ D n ] . Then:
(a) ( 1 − e − 1 ) k e f f ≤ s n ′ ≤ k e f f (1-e^{-1})k_{\mathrm{eff}}\leq s'_n\leq k_{\mathrm{eff}} ( 1 − e − 1 ) k eff ≤ s n ′ ≤ k eff ;
(b) for every δ ∈ ( 0 , 1 ) \delta\in(0,1) δ ∈ ( 0 , 1 ) , P S ( D n ≥ 2 k e f f + 2 log 1 δ ) ≤ δ \mathbb{P}_S\left(D_n\geq2k_{\mathrm{eff}}+2\log\frac{1}{\delta}\right)\leq\delta P S ( D n ≥ 2 k eff + 2 log δ 1 ) ≤ δ ;
(c) P S ( D n ≤ 0.3 k e f f ) ≤ e − k e f f / 21 \mathbb{P}_{S}(D_n \le0.3 k_{\mathrm{eff}}) \le e^{-k_{\mathrm{eff}}/21} P S ( D n ≤ 0.3 k eff ) ≤ e − k eff /21 .
Proof. (a) We begin noticing that D n = ∑ x 1 { N 0 ( x ) > 0 } D_n = \sum_x 1\{N_0(x) > 0\} D n = ∑ x 1 { N 0 ( x ) > 0 } and N 0 ( x ) ∼ Bin ( n , μ d a t a ( x ) ) N_0(x) \sim\operatorname{Bin}(n,\mu_{\mathrm{data}}(x)) N 0 ( x ) ∼ Bin ( n , μ data ( x )) , so we have
s n ′ = ∑ x [ 1 − ( 1 − μ d a t a ( x ) ) n ] . s'_n = \sum_x [1 - (1-\mu_{\mathrm{data}}(x))^n]. s n ′ = x ∑ [ 1 − ( 1 − μ data ( x ) ) n ] .
For p ∈ [ 0 , 1 ] p \in[0,1] p ∈ [ 0 , 1 ] , Bernoulli’s inequality ( 1 − p ) n ≥ 1 − n p (1-p)^n \ge1-np ( 1 − p ) n ≥ 1 − n p gives 1 − ( 1 − p ) n ≤ min { 1 , n p } 1-(1-p)^n \le\min\{1,np\} 1 − ( 1 − p ) n ≤ min { 1 , n p } ; conversely 1 − ( 1 − p ) n ≥ 1 − e − n p ≥ ( 1 − e − 1 ) min { 1 , n p } 1-(1-p)^n \ge1-e^{-np} \ge(1-e^{-1})\min\{1,np\} 1 − ( 1 − p ) n ≥ 1 − e − n p ≥ ( 1 − e − 1 ) min { 1 , n p } , because u ↦ 1 − e − u u \mapsto1-e^{-u} u ↦ 1 − e − u is nondecreasing and concave with value 1 − e − 1 1-e^{-1} 1 − e − 1 at u = 1 u=1 u = 1 . Summing over x x x and recalling k e f f = ∑ x min { 1 , n μ d a t a ( x ) } k_{\mathrm{eff}} = \sum_x \min\{1,n\mu_{\mathrm{data}}(x)\} k eff = ∑ x min { 1 , n μ data ( x )} , we obtain (a).
(b)–(c) We notice now that the indicators 1 { N 0 ( x ) > 0 } 1\{N_0(x)>0\} 1 { N 0 ( x ) > 0 } , x ∈ X 0 x \in\mathcal{X}_0 x ∈ X 0 , are negatively associated, see [7 ] . Thus, D n = ∑ x 1 { N 0 ( x ) > 0 } D_n = \sum_x 1\{N_0(x)>0\} D n = ∑ x 1 { N 0 ( x ) > 0 } satisfies the Chernoff bounds of a sum of independent Bernoulli variables with the same means, see [3 ] for more details: for every s > s n ′ s>s'_n s > s n ′ and every s < s n ′ s<s'_n s < s n ′ respectively,
P ( D n ≥ s ) ≤ exp ( − D ( s , s n ′ ) ) , P ( D n ≤ s ) ≤ exp ( − D ( s , s n ′ ) ) , D ( u , v ) = u log u v − u + v . \mathbb{P}(D_n \ge s) \le\exp\left(-D(s,s'_n)\right), \qquad\mathbb{P}(D_n \le s) \le\exp\left(-D(s,s'_n)\right), \qquad D(u,v)=u\log\frac{u}{v}-u+v. P ( D n ≥ s ) ≤ exp ( − D ( s , s n ′ ) ) , P ( D n ≤ s ) ≤ exp ( − D ( s , s n ′ ) ) , D ( u , v ) = u log v u − u + v .
Let denote now L : = log ( 1 δ ) L:=\log\left(\frac{1}{\delta}\right) L := log ( δ 1 ) and s : = 2 ( s n ′ + L ) s:=2(s'_n+L) s := 2 ( s n ′ + L ) . With u : = s s n ′ = 2 + 2 ℓ u:=\frac{s}{s'_n}=2+2\ell u := s n ′ s = 2 + 2 ℓ , where ℓ : = L / s n ′ \ell:=L/s'_n ℓ := L / s n ′ , we have D ( s , s n ′ ) = s n ′ ( ( 2 + 2 ℓ ) log ( 2 + 2 ℓ ) − ( 1 + 2 ℓ ) ) D(s,s'_n)=s'_n((2+2\ell)\log(2+2\ell)-(1+2\ell)) D ( s , s n ′ ) = s n ′ (( 2 + 2 ℓ ) log ( 2 + 2 ℓ ) − ( 1 + 2 ℓ )) . Now, when ℓ = 0 \ell=0 ℓ = 0 , the quantity inside the parentheses is equal to 2 log 2 − 1 > 0 2\log2-1>0 2 log 2 − 1 > 0 and for a generic ℓ \ell ℓ its derivative is 2 log ( 2 + 2 ℓ ) ≥ 2 log 2 > 1 2\log(2+2\ell)\ge2\log2>1 2 log ( 2 + 2 ℓ ) ≥ 2 log 2 > 1 , so ( 2 + 2 ℓ ) log ( 2 + 2 ℓ ) − ( 1 + 2 ℓ ) ≥ ℓ (2+2\ell)\log(2+2\ell)-(1+2\ell)\ge\ell ( 2 + 2 ℓ ) log ( 2 + 2 ℓ ) − ( 1 + 2 ℓ ) ≥ ℓ and D ( s , s n ′ ) ≥ L D(s,s'_n)\ge L D ( s , s n ′ ) ≥ L . Hence
P ( D n ≥ 2 ( s n ′ + L ) ) ≤ δ , \mathbb{P}(D_n \ge2(s'_n+L)) \le\delta, P ( D n ≥ 2 ( s n ′ + L )) ≤ δ ,
and since s n ′ ≤ k e f f s'_n \le k_{\mathrm{eff}} s n ′ ≤ k eff by (a),
{ D n ≥ 2 k e f f + 2 L } ⊆ { D n ≥ 2 ( s n ′ + L ) } . \{D_n \ge2k_{\mathrm{eff}}+2L\} \subseteq\{D_n \ge2(s'_n+L)\}. { D n ≥ 2 k eff + 2 L } ⊆ { D n ≥ 2 ( s n ′ + L )} .
This proves (b).
Take now s : = s n ′ 2 s:=\frac{s'_n}{2} s := 2 s n ′ :
D ( s n ′ 2 , s n ′ ) = 1 − log 2 2 s n ′ ≥ ( 1 − log 2 ) ( 1 − e − 1 ) 2 k e f f ≥ k e f f 21 D\left(\frac{s'_n}{2},s'_n\right)=\frac{1-\log2}{2}s'_n \ge\frac{(1-\log2)(1-e^{-1})}{2}k_{\mathrm{eff}} \ge\frac{k_{\mathrm{eff}}}{21} D ( 2 s n ′ , s n ′ ) = 2 1 − log 2 s n ′ ≥ 2 ( 1 − log 2 ) ( 1 − e − 1 ) k eff ≥ 21 k eff
by (a), and s n ′ 2 ≥ 1 − e − 1 2 k e f f ≥ 0.3 k e f f \frac{s'_n}{2}\ge\frac{1-e^{-1}}{2}k_{\mathrm{eff}}\ge0.3k_{\mathrm{eff}} 2 s n ′ ≥ 2 1 − e − 1 k eff ≥ 0.3 k eff , so
{ D n ≤ 0.3 k e f f } ⊆ { D n ≤ s n ′ / 2 } . \{D_n \le0.3k_{\mathrm{eff}}\}\subseteq\{D_n\le s'_n/2\}. { D n ≤ 0.3 k eff } ⊆ { D n ≤ s n ′ /2 } .
This concludes.
We recall now the following result.
Proposition 3 ([12 ] , Proposition 2). Let n , K d ≥ 2 n,K^d\ge2 n , K d ≥ 2 . Then
E S KL ( μ d a t a ∣ μ ^ 0 ( D n ) ) ≤ 2.4 k e f f + 2 k e f f o ( μ d a t a , n / 2 ) log ( e K d / k e f f o ( μ d a t a , n / 2 ) ) n + 1 . \mathbb{E}_{S}\operatorname{KL}(\mu_{\mathrm{data}}\mid\widehat{\mu}_0^{(D_n)})\le\frac{2.4k_{\mathrm{eff}}+2k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/2)\log\left(eK^d/k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/2)\right)}{n+1}. E S KL ( μ data ∣ μ 0 ( D n ) ) ≤ n + 1 2.4 k eff + 2 k eff o ( μ data , n /2 ) log ( e K d / k eff o ( μ data , n /2 ) ) .
Thanks to the results above, we can now prove that if we take γ = D n \gamma=D_n γ = D n , we have an adaptive estimator that reaches the minimax rates. We prove it in the following corollary.
Corollary 4 (Adaptive smoothing). Let us take γ = D n \gamma= D_n γ = D n , μ ^ 0 = μ ^ 0 ( D n ) \hat{\mu}_0 = \hat{\mu}_0^{(D_n)} μ ^ 0 = μ ^ 0 ( D n ) and let us call for simplicity k : = k e f f k := k_{\mathrm{eff}} k := k eff . Then, the following holds.
(i) If n , K d ≥ 2 n, K^d \ge2 n , K d ≥ 2 ,
E S KL ( μ d a t a ∣ μ ^ 0 ) ≤ 2.4 k + 2 k e f f o ( μ d a t a , n / 2 ) log ( e K d / k e f f o ( μ d a t a , n / 2 ) ) n + 1 . \mathbb{E}_{S}\operatorname{KL}(\mu_{\mathrm{data}} \mid\hat{\mu}_0) \le\frac{2.4\,k + 2k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/2)\log\left(eK^d/k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/2)\right)}{n+1}. E S KL ( μ data ∣ μ ^ 0 ) ≤ n + 1 2.4 k + 2 k eff o ( μ data , n /2 ) log ( e K d / k eff o ( μ data , n /2 ) ) . (ii) If n ≥ 13 n \ge13 n ≥ 13 , K d ≥ 3 K^d \ge3 K d ≥ 3 and δ ∈ ( e − n / 6 , e − 2 ) \delta\in(e^{-n/6},e^{-2}) δ ∈ ( e − n /6 , e − 2 ) , then with probability at least 1 − 14 δ 1-14\delta 1 − 14 δ ,
KL ( μ d a t a ∣ μ ^ 0 ) ≤ 130000 k + k e f f o ( μ d a t a , n / 112 ) log ( e K d / k ) + log ( K d ) log 1 δ + log 1 δ log log 1 δ n . \operatorname{KL}(\mu_{\mathrm{data}} \mid\hat{\mu}_0) \le130000\frac{k+k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)\log(eK^d/k)+\log(K^d)\log\frac{1}{\delta}+\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}. KL ( μ data ∣ μ ^ 0 ) ≤ 130000 n k + k eff o ( μ data , n /112 ) log ( e K d / k ) + log ( K d ) log δ 1 + log δ 1 log log δ 1 . In particular, for μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}_l(\mathcal{X}_0) μ data ∈ P l ( X 0 ) with 2 ≤ l ≤ min { n , ⌊ K d / 55 ⌋ } 2 \le l \le\min\{n,\lfloor K^d/55\rfloor\} 2 ≤ l ≤ min { n , ⌊ K d /55 ⌋} and δ ≥ e − K d \delta\ge e^{-K^d} δ ≥ e − K d , the right-hand sides are at most
C l log ( e K d / l ) n and C Γ δ n , C\frac{l\log(eK^d/l)}{n}
\qquad\text{and}\qquad
C\frac{\Gamma_\delta}{n}, C n l log ( e K d / l ) and C n Γ δ , simultaneously for every l l l as above. Thus, under the assumptions of Corollary 2, the upper bounds in its two items hold for ν ^ \hat{\nu} ν ^ driven by s ^ = s ^ ( D n ) \hat{s}=\hat{s}^{(D_n)} s ^ = s ^ ( D n ) , with the same estimator and the same event for every l l l , and ν ^ \hat{\nu} ν ^ is minimax optimal over P l ( X 0 ) \mathcal{P}_l(\mathcal{X}_0) P l ( X 0 ) in both senses.
Proof of Corollary 4. (i) follows immediately from Proposition 3.
(ii) Let A A A be the event of Lemma 3, P S ( A ) ≥ 1 − 12 δ \mathbb{P}_S(A) \ge1-12\delta P S ( A ) ≥ 1 − 12 δ , and B : = { D n < 2 k e f f + 2 log 1 δ } B := \{D_n < 2k_{\mathrm{eff}}+2\log\frac{1}{\delta}\} B := { D n < 2 k eff + 2 log δ 1 } , P S ( B ) ≥ 1 − δ \mathbb{P}_S(B) \ge1-\delta P S ( B ) ≥ 1 − δ by Lemma 16 (b). Since 1 ≤ D n ≤ min { n , K d } 1 \le D_n \le\min\{n,K^d\} 1 ≤ D n ≤ min { n , K d } , the parameter γ = D n \gamma=D_n γ = D n is admissible in Lemma 3. On the event A ∩ B A\cap B A ∩ B , its explicit form with γ = D n \gamma=D_n γ = D n and 7 D n ≤ 14 k e f f + 14 log 1 δ 7D_n \le14k_{\mathrm{eff}}+14\log\frac{1}{\delta} 7 D n ≤ 14 k eff + 14 log δ 1 give
KL ( μ d a t a ∣ μ ^ 0 ) ≤ 63114 k e f f + 56 log 1 δ + ( 336 k e f f o ( μ d a t a , n / 112 ) + 6796 log 1 δ ) L D n n + 106000 log 1 δ log log 1 δ n . (67) \begin{aligned}
\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0)\le\frac{63114k_{\mathrm{eff}}+56\log\frac{1}{\delta}+\left(336k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)+6796\log\frac{1}{\delta}\right)L_{D_n}}{n} \\
&+\frac{106000\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}. \tag*{(67)}
\end{aligned} KL ( μ data ∣ μ ^ 0 ) ≤ n 63114 k eff + 56 log δ 1 + ( 336 k eff o ( μ data , n /112 ) + 6796 log δ 1 ) L D n + n 106000 log δ 1 log log δ 1 . (67)
We still need to bound L D n = log ( e K d / D n ) L_{D_n}=\log(eK^d/D_n) L D n = log ( e K d / D n ) . Since K d ≥ 3 K^d\ge3 K d ≥ 3 , log K d ≥ 1 \log K^d\ge1 log K d ≥ 1 and log ( e K d ) = 1 + log K d ≤ 2 log K d \log(eK^d)=1+\log K^d\le2\log K^d log ( e K d ) = 1 + log K d ≤ 2 log K d ; then, since D n ≥ 1 D_n\ge1 D n ≥ 1 , L D n ≤ log ( e K d ) ≤ 2 log K d L_{D_n}\le\log(eK^d)\le2\log K^d L D n ≤ log ( e K d ) ≤ 2 log K d always.
We study now the case k e f f ≥ 21 log 1 δ k_{\mathrm{eff}}\ge21\log\frac{1}{\delta} k eff ≥ 21 log δ 1 . Let E : = { D n > 0.3 k e f f } E:=\{D_n>0.3k_{\mathrm{eff}}\} E := { D n > 0.3 k eff } . Thanks to Lemma 16 (c), we know that P S ( E c ) ≤ e − k e f f / 21 ≤ δ \mathbb{P}_S(E^c)\le e^{-k_{\mathrm{eff}}/21}\le\delta P S ( E c ) ≤ e − k eff /21 ≤ δ . On E E E ,
L D n ≤ log e K d 0.3 k e f f = log e K d k e f f + log 10 3 ≤ log e K d k e f f + 1.21 ≤ 2.21 log e K d k e f f , L_{D_n}\le\log\frac{eK^d}{0.3k_{\mathrm{eff}}}=\log\frac{eK^d}{k_{\mathrm{eff}}}+\log\frac{10}{3}\le\log\frac{eK^d}{k_{\mathrm{eff}}}+1.21\le2.21\log\frac{eK^d}{k_{\mathrm{eff}}}, L D n ≤ log 0.3 k eff e K d = log k eff e K d + log 3 10 ≤ log k eff e K d + 1.21 ≤ 2.21 log k eff e K d ,
because k e f f ≤ K d k_{\mathrm{eff}}\le K^d k eff ≤ K d gives log e K d k e f f ≥ 1 \log\frac{eK^d}{k_{\mathrm{eff}}}\ge1 log k eff e K d ≥ 1 . So, on A ∩ B ∩ E A\cap B\cap E A ∩ B ∩ E , of probability at least 1 − 14 δ 1-14\delta 1 − 14 δ ,
336 k e f f o ( μ d a t a , n / 112 ) L D n ≤ 743 k e f f o ( μ d a t a , n / 112 ) log e K d k e f f 336k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)L_{D_n}\le743k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)\log\frac{eK^d}{k_{\mathrm{eff}}} 336 k eff o ( μ data , n /112 ) L D n ≤ 743 k eff o ( μ data , n /112 ) log k eff e K d
and
6796 log 1 δ L D n ≤ 13592 log ( K d ) log 1 δ . 6796\log\frac{1}{\delta}L_{D_n}\le13592\log(K^d)\log\frac{1}{\delta}. 6796 log δ 1 L D n ≤ 13592 log ( K d ) log δ 1 .
On the other hand, in the case k e f f < 21 log 1 δ k_{\mathrm{eff}}<21\log\frac{1}{\delta} k eff < 21 log δ 1 , on A ∩ B A\cap B A ∩ B , of probability at least 1 − 13 δ 1-13\delta 1 − 13 δ , using k e f f o ( μ d a t a , n / 112 ) ≤ k e f f < 21 log 1 δ k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)\le k_{\mathrm{eff}}<21\log\frac{1}{\delta} k eff o ( μ data , n /112 ) ≤ k eff < 21 log δ 1 and L D n ≤ 2 log K d L_{D_n}\le2\log K^d L D n ≤ 2 log K d , we have
336 k e f f o ( μ d a t a , n / 112 ) L D n ≤ 336 ⋅ 21 ⋅ 2 log ( K d ) log 1 δ = 14112 log ( K d ) log 1 δ . 336k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)L_{D_n}\le336\cdot21\cdot2\log(K^d)\log\frac{1}{\delta}=14112\log(K^d)\log\frac{1}{\delta}. 336 k eff o ( μ data , n /112 ) L D n ≤ 336 ⋅ 21 ⋅ 2 log ( K d ) log δ 1 = 14112 log ( K d ) log δ 1 .
and
6796 log 1 δ D n ≤ 13592 log ( K d ) log 1 δ . 6796\log\frac{1}{\delta}D_n \le13592\log(K^d)\log\frac{1}{\delta}. 6796 log δ 1 D n ≤ 13592 log ( K d ) log δ 1 .
In both cases, inserting into (66) and using 56 log 1 δ ≤ 56 log ( K d ) log 1 δ 56\log\frac{1}{\delta}\le56\log(K^d)\log\frac{1}{\delta} 56 log δ 1 ≤ 56 log ( K d ) log δ 1 , with probability at least 1 − 14 δ 1-14\delta 1 − 14 δ ,
KL ( μ d a t a ∣ μ ^ 0 ) ≤ 63114 k e f f + 743 k e f f o ( μ d a t a , n / 112 ) log e K d k e f f + 27760 log ( K d ) log 1 δ n \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0)\le\frac{63114\,k_{\mathrm{eff}}+743\,k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)\log\frac{eK^d}{k_{\mathrm{eff}}}+27760\log(K^d)\log\frac{1}{\delta}}{n} KL ( μ data ∣ μ ^ 0 ) ≤ n 63114 k eff + 743 k eff o ( μ data , n /112 ) log k eff e K d + 27760 log ( K d ) log δ 1
+ 106000 log 1 δ log log 1 δ n , \qquad+\frac{106000\log\frac{1}{\delta}\log\log\frac{1}{\delta}}{n}, + n 106000 log δ 1 log log δ 1 ,
which implies the claim.
We focus now on the sparse case. Let μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}}\in\mathcal{P}_l(\mathcal{X}_0) μ data ∈ P l ( X 0 ) with 2 ≤ l ≤ min { n , ⌊ K d / 55 ⌋ } 2\le l\le\min\{n,\lfloor K^d/55\rfloor\} 2 ≤ l ≤ min { n , ⌊ K d /55 ⌋} and δ ≥ e − K d \delta\ge e^{-K^d} δ ≥ e − K d . We note that Λ l ≥ 1 \Lambda_l\ge1 Λ l ≥ 1 , and we are going to use k e f f o ( μ d a t a , m ) ≤ k ≤ l k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},m)\le k\le l k eff o ( μ data , m ) ≤ k ≤ l , the monotonicity of u ↦ u log ( e K d / u ) u\mapsto u\log(eK^d/u) u ↦ u log ( e K d / u ) on [ 1 , min { n , K d } ] [1,\min\{n,K^d\}] [ 1 , min { n , K d }] , and that log log 1 δ ≤ log ( K d ) \log\log\frac{1}{\delta}\le\log(K^d) log log δ 1 ≤ log ( K d ) .
By (65), k e f f o ( μ d a t a , m ) ≤ k e f f ≤ l ≤ K d k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},m)\le k_{\mathrm{eff}}\le l\le K^d k eff o ( μ data , m ) ≤ k eff ≤ l ≤ K d for m ≤ n m\le n m ≤ n , hence k e f f ≤ l Λ l k_{\mathrm{eff}}\le l\Lambda_l k eff ≤ l Λ l and, thanks to monotonicity,
k e f f o ( μ d a t a , n / 2 ) log e K d k e f f o ( μ d a t a , n / 2 ) ≤ l Λ l k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/2)\log\frac{eK^d}{k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/2)}\le l\Lambda_l k eff o ( μ data , n /2 ) log k eff o ( μ data , n /2 ) e K d ≤ l Λ l
and
k e f f o ( μ d a t a , n / 112 ) log e K d k e f f ≤ k e f f log e K d k e f f ≤ l Λ l . k_{\mathrm{eff}}^{o}(\mu_{\mathrm{data}},n/112)\log\frac{eK^d}{k_{\mathrm{eff}}}\le k_{\mathrm{eff}}\log\frac{eK^d}{k_{\mathrm{eff}}}\le l\Lambda_l. k eff o ( μ data , n /112 ) log k eff e K d ≤ k eff log k eff e K d ≤ l Λ l .
Therefore (i) gives
E S KL ( μ d a t a ∣ μ ^ 0 ) ≤ ( 2.4 + 2 ) l Λ l n = 4.4 l Λ l n , \mathrm{E}_{\mathrm S}\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0)\le\frac{(2.4+2)l\Lambda_l}{n}=\frac{4.4\,l\Lambda_l}{n}, E S KL ( μ data ∣ μ ^ 0 ) ≤ n ( 2.4 + 2 ) l Λ l = n 4.4 l Λ l ,
and (ii) gives, with probability at least 1 − 14 δ 1-14\delta 1 − 14 δ since δ ≥ e − K d \delta\ge e^{-K^d} δ ≥ e − K d implies log log 1 δ ≤ log K d \log\log\frac{1}{\delta}\le\log K^d log log δ 1 ≤ log K d ,
KL ( μ d a t a ∣ μ ^ 0 ) ≤ 130000 2 l Λ l + 2 log ( K d ) log 1 δ n = 260000 Γ δ n . \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0)\le130000\frac{2l\Lambda_l+2\log(K^d)\log\frac{1}{\delta}}{n}=260000\frac{\Gamma_\delta}{n}. KL ( μ data ∣ μ ^ 0 ) ≤ 130000 n 2 l Λ l + 2 log ( K d ) log δ 1 = 260000 n Γ δ .
We observe that neither μ ^ 0 ( D n ) \hat{\mu}_0^{(D_n)} μ ^ 0 ( D n ) nor the events A ∩ B ∩ E A\cap B\cap E A ∩ B ∩ E , A ∩ B A\cap B A ∩ B depend on l l l , so both bounds hold simultaneously for every l l l with μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}}\in\mathcal{P}_l(\mathcal{X}_0) μ data ∈ P l ( X 0 ) .
To finish, we transfer this bounds to the sampler. For every fixed sample S S S , μ ^ 0 ( D n ) \hat{\mu}_0^{(D_n)} μ ^ 0 ( D n ) is a strictly positive law on X 0 \mathcal{X}_0 X 0 and s ^ ( D n ) \hat{s}^{(D_n)} s ^ ( D n ) is its plug-in score. Thus, Lemma 4, applied conditionally on S S S , gives
KL ( μ d a t a ∣ ν ^ ) = KL ( μ d a t a ∣ μ ^ 0 ) \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})=\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0) KL ( μ data ∣ ν ^ ) = KL ( μ data ∣ μ ^ 0 )
for the masked kernel and
KL ( μ d a t a ∣ ν ^ ) ≤ KL ( μ d a t a ∣ μ ^ 0 ) + 1 n \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu})\le\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0)+\frac{1}{n} KL ( μ data ∣ ν ^ ) ≤ KL ( μ data ∣ μ ^ 0 ) + n 1
for the uniform kernel, with for the latter the additional hypothesis σ ‾ T ≥ log ( d K n ) \overline{\sigma}_T\ge\log(dKn) σ T ≥ log ( d K n ) . Since 1 n ≤ l Λ l n ≤ Γ δ n \frac{1}{n}\le\frac{l\Lambda_l}{n}\le\frac{\Gamma_\delta}{n} n 1 ≤ n l Λ l ≤ n Γ δ , ν ^ \hat{\nu} ν ^ satisfies the upper bounds of Corollary 2 with constants 5.4 and 260001, with the same event for every l l l . This concludes. □
Above we proved that we reach minimax rates with γ = D n \gamma=D_n γ = D n . For completeness, we prove here also that the same rates are reachable if γ \gamma γ is inside of an interval dependent of the sparsity parameter l l l . Since this parameter is unknown, the previous corollary gave us a way to implement a valid choice of γ \gamma γ despite the fact that we don’t know l l l . Moreover, let us notice that D n D_n D n is in general close tu k e f f k_{\mathrm{eff}} k eff , not l l l , so it may be outside of the interval. This means Corollary 4 and Corollary 2 prove the same rates for potentially different values of γ \gamma γ .
Proof of Corollary 2. Since the proof is the same for both kernels, we are going to explain it for both masked and uniform diffusion. Throughout μ d a t a ∈ P ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}(\mathcal{X}_0) μ data ∈ P ( X 0 ) , so k e f f ( μ d a t a , m ) ≤ k e f f ≤ l k_{\mathrm{eff}}(\mu_{\mathrm{data}},m) \le k_{\mathrm{eff}} \le l k eff ( μ data , m ) ≤ k eff ≤ l for every m ≤ n m \le n m ≤ n . Also, since l ≤ K d / 55 l \le K^d/55 l ≤ K d /55 , it holds Λ l ≥ log ( 55 e ) > 5 \Lambda_l \ge\log(55e) > 5 Λ l ≥ log ( 55 e ) > 5 . Furthermore, K d ≥ 110 K^d \ge110 K d ≥ 110 implies Λ l ≤ 1 + log K d ≤ 2 log K d \Lambda_l \le1+\log K^d \le2\log K^d Λ l ≤ 1 + log K d ≤ 2 log K d ; and 1 ≤ l ≤ l Λ l ≤ Γ δ 1 \le l \le l\Lambda_l \le\Gamma_\delta 1 ≤ l ≤ l Λ l ≤ Γ δ .
We fix a sample S S S and we call the its potentially associated density μ ^ 0 ( γ ( S ) ) \widehat{\mu}_0^{(\gamma(S))} μ 0 ( γ ( S )) , which is a strictly positive law on X 0 \mathcal{X}_0 X 0 , and s ^ \widehat{s} s is its score. Lemma 4 gives
KL ( μ d a t a ∣ ν ^ ) = KL ( μ d a t a ∣ μ ^ 0 ) \operatorname{KL}(\mu_{\mathrm{data}} \mathbin| \widehat{\nu}) = \operatorname{KL}(\mu_{\mathrm{data}} \mathbin| \widehat{\mu}_0) KL ( μ data ∣ ν ) = KL ( μ data ∣ μ 0 )
for the masked case, while Lemma 5, under the hypothesis σ ‾ T ≥ log ( d K n ) \overline{\sigma}_T \ge\log(dKn) σ T ≥ log ( d K n ) , gives
KL ( μ d a t a ∣ ν ^ ) ≤ KL ( μ d a t a ∣ μ ^ 0 ) + 1 n . \operatorname{KL}(\mu_{\mathrm{data}} \mathbin| \widehat{\nu}) \le\operatorname{KL}(\mu_{\mathrm{data}} \mathbin| \widehat{\mu}_0) + \frac{1}{n}. KL ( μ data ∣ ν ) ≤ KL ( μ data ∣ μ 0 ) + n 1 .
for the uniform kernel. As 1 n ≤ l Λ l n ≤ Γ δ n \frac{1}{n} \le\frac{l\Lambda_l}{n} \le\frac{\Gamma_\delta}{n} n 1 ≤ n l Λ l ≤ n Γ δ , it suffices to prove the upper bounds for μ ^ 0 \widehat{\mu}_0 μ 0 with constant C − 1 C-1 C − 1 .
Let γ 0 : = max { 1 , c 0 l } \gamma_0 := \max\{1,c_0l\} γ 0 := max { 1 , c 0 l } be a deterministic element of [ 1 , min { n , K d } ] [1,\min\{n,K^d\}] [ 1 , min { n , K d }] since c 0 ≤ 1 c_0 \le1 c 0 ≤ 1 and l ≤ min { n , K d } l \le\min\{n,K^d\} l ≤ min { n , K d } ; by assumption γ ≥ γ 0 \gamma\ge\gamma_0 γ ≥ γ 0 surely. If c 0 l ≥ 1 c_0l \ge1 c 0 l ≥ 1 then L γ 0 = log e K d c 0 l = Λ l + log 1 c 0 L_{\gamma_0} = \log\frac{eK^d}{c_0l} = \Lambda_l+\log\frac{1}{c_0} L γ 0 = log c 0 l e K d = Λ l + log c 0 1 ; on the other side, if c 0 l < 1 c_0l < 1 c 0 l < 1 then γ 0 = 1 \gamma_0 = 1 γ 0 = 1 and L γ 0 = Λ l + log l ≤ Λ l + log 1 c 0 L_{\gamma_0} = \Lambda_l+\log l \le\Lambda_l+\log\frac{1}{c_0} L γ 0 = Λ l + log l ≤ Λ l + log c 0 1 . Since u ↦ L u u \mapsto L_u u ↦ L u is nonincreasing,
L γ ≤ L γ 0 ≤ Λ l + log 1 c 0 ≤ c 1 Λ l , c 1 : = 1 + log ( 1 / c 0 ) log ( 55 e ) , L_\gamma\le L_{\gamma_0} \le\Lambda_l+\log\frac{1}{c_0} \le c_1\Lambda_l,\qquad c_1 := 1+\frac{\log(1/c_0)}{\log(55e)}, L γ ≤ L γ 0 ≤ Λ l + log c 0 1 ≤ c 1 Λ l , c 1 := 1 + log ( 55 e ) log ( 1/ c 0 ) ,
where we used Λ l ≥ log ( 55 e ) \Lambda_l \ge\log(55e) Λ l ≥ log ( 55 e ) .
We apply Lemma 2, with n ≥ 110 ≥ 8 n \ge110 \ge8 n ≥ 110 ≥ 8 and this γ 0 \gamma_0 γ 0 : P S ( γ < γ 0 ) = 0 \mathbb{P}_S(\gamma< \gamma_0)=0 P S ( γ < γ 0 ) = 0 , E S [ γ ] ≤ C 0 l Λ l \mathbb{E}_S[\gamma] \le C_0l\Lambda_l E S [ γ ] ≤ C 0 l Λ l , k e f f ≤ l k_{\mathrm{eff}} \le l k eff ≤ l , k e f f o ( μ d a t a , n / 8 ) ≤ l k_{\mathrm{eff}}^o(\mu_{\mathrm{data}},n/8) \le l k eff o ( μ data , n /8 ) ≤ l . With the explicit constants of the proof of Lemma 2,
E S KL ( μ d a t a ∣ μ ^ 0 ) ≤ 12 l + 7 C 0 l Λ l + ( 23 + 8 L γ 0 ) l n ≤ ( 12 + 7 C 0 + 31 c 1 ) l Λ l n . \mathbb{E}_S\operatorname{KL}(\mu_{\mathrm{data}} \mathbin| \widehat{\mu}_0) \le\frac{12l+7C_0l\Lambda_l+(23+8L_{\gamma_0})l}{n} \le\frac{(12+7C_0+31c_1)l\Lambda_l}{n}. E S KL ( μ data ∣ μ 0 ) ≤ n 12 l + 7 C 0 l Λ l + ( 23 + 8 L γ 0 ) l ≤ n ( 12 + 7 C 0 + 31 c 1 ) l Λ l .
Thanks to the results above, this gives the first item with C 1 : = 13 + 7 C 0 + 31 c 1 C_1 := 13+7C_0+31c_1 C 1 := 13 + 7 C 0 + 31 c 1 .
We now work on the upper bound of the second item. Let A A A be the event of Lemma 3, which is applicable since n ≥ 13 n \ge13 n ≥ 13 , K d ≥ 3 K^d \ge3 K d ≥ 3 , δ ∈ ( e − n / 6 , e − 2 ) \delta\in(e^{-n/6},e^{-2}) δ ∈ ( e − n /6 , e − 2 ) , we have P S ( A ) ≥ 1 − 12 δ \mathbb{P}_S(A) \ge1-12\delta P S ( A ) ≥ 1 − 12 δ , on which the bound holds simultaneously for every γ ∈ [ 1 , min { n , K d } ] \gamma\in[1,\min\{n,K^d\}] γ ∈ [ 1 , min { n , K d }] , hence for the random γ \gamma γ . On A A A , with the explicit constants of the proof of Lemma 3, k e f f , k e f f o ( μ d a t a , n / 112 ) ≤ l ≤ l Λ l k_{\mathrm{eff}}, k_{\mathrm{eff}}^o(\mu_{\mathrm{data}},n/112) \le l \le l\Lambda_l k eff , k eff o ( μ data , n /112 ) ≤ l ≤ l Λ l , γ ≤ C 0 Γ δ \gamma\le C_0\Gamma_\delta γ ≤ C 0 Γ δ , L γ ≤ c 1 Λ l ≤ 2 c 1 log K d L_\gamma\le c_1\Lambda_l \le2c_1\log K^d L γ ≤ c 1 Λ l ≤ 2 c 1 log K d , log ( 1 / δ ) ≤ log ( K d ) log ( 1 / δ ) \log(1/\delta) \le\log(K^d)\log(1/\delta) log ( 1/ δ ) ≤ log ( K d ) log ( 1/ δ ) , log log ( 1 / δ ) ≤ log K d \log\log(1/\delta) \le\log K^d log log ( 1/ δ ) ≤ log K d , since δ ≥ e − K d \delta\ge e^{-K^d} δ ≥ e − K d , it holds
KL ( μ d a t a ∣ μ ^ 0 ) ≤ ( 63100 + 336 c 1 ) l Λ l + 7 C 0 Γ δ + ( 106042 + 13592 c 1 ) log ( K d ) log 1 δ n ≤ ( 169150 + 7 C 0 + 13928 c 1 ) Γ δ n . \operatorname{KL}(\mu_{\mathrm{data}} \mathbin| \widehat{\mu}_0) \le\frac{(63100+336c_1)l\Lambda_l+7C_0\Gamma_\delta+(106042+13592c_1)\log(K^d)\log\frac{1}{\delta}}{n}
\le\frac{(169150+7C_0+13928c_1)\Gamma_\delta}{n}. KL ( μ data ∣ μ 0 ) ≤ n ( 63100 + 336 c 1 ) l Λ l + 7 C 0 Γ δ + ( 106042 + 13592 c 1 ) log ( K d ) log δ 1 ≤ n ( 169150 + 7 C 0 + 13928 c 1 ) Γ δ .
With the results above, this gives the upper bound of the second item with C 2 : = 169151 + 7 C 0 + 13928 c 1 C_2 := 169151+7C_0+13928c_1 C 2 := 169151 + 7 C 0 + 13928 c 1 . Set C : = max { C 1 , C 2 } C := \max\{C_1,C_2\} C := max { C 1 , C 2 } , which depends only on ( c 0 , C 0 ) (c_0,C_0) ( c 0 , C 0 ) .
For completeness, we also prove that the upper bounds of the first and second item match the minimax lower bounds up to universal constants. Let S ↦ ν S ∈ P ( X ) S \mapsto\nu_S \in\mathcal{P}(\mathcal{X}) S ↦ ν S ∈ P ( X ) be measurable. Define ν ~ S : = ν S ( ⋅ ∣ X 0 ) \widetilde{\nu}_S := \nu_S(\mathord{\cdot}\mid\mathcal{X}_0) ν S := ν S ( ⋅ ∣ X 0 ) if ν S ( X 0 ) > 0 \nu_S(\mathcal{X}_0)>0 ν S ( X 0 ) > 0 and ν ~ S \widetilde{\nu}_S ν S a fixed element of P ( X 0 ) \mathcal{P}(\mathcal{X}_0) P ( X 0 ) otherwise: for the uniform kernel X = X 0 \mathcal{X}=\mathcal{X}_0 X = X 0 and ν ~ S = ν S \widetilde{\nu}_S=\nu_S ν S = ν S in particular. Now, for every μ ∈ P ( X 0 ) \mu\in\mathcal{P}(\mathcal{X}_0) μ ∈ P ( X 0 ) ,
KL ( μ ∣ ν S ) ≥ KL ( μ ∣ ν ~ S ) . \operatorname{KL}(\mu\mathbin|\nu_S) \ge\operatorname{KL}(\mu\mathbin|\widetilde{\nu}_S). KL ( μ ∣ ν S ) ≥ KL ( μ ∣ ν S ) .
In fact, if ν S ( X 0 ) = 0 \nu_S(\mathcal{X}_0)=0 ν S ( X 0 ) = 0 the left side is + ∞ +\infty + ∞ , otherwise ν ~ S ≥ ν S \widetilde{\nu}_S \ge\nu_S ν S ≥ ν S on X 0 \mathcal{X}_0 X 0 . The map S ↦ ν ~ S S \mapsto\widetilde{\nu}_S S ↦ ν S is an estimator X 0 n → P ( X 0 ) \mathcal{X}_0^n \to\mathcal{P}(\mathcal{X}_0) X 0 n → P ( X 0 ) , so Corollary 3 applies with ∣ X ∣ = K d |\mathcal{X}|=K^d ∣ X ∣ = K d ; its hypotheses n , K d ≥ 110 n,K^d \ge110 n , K d ≥ 110 , l ∈ { 2 , … , min ( n , ⌊ K d / 55 ⌋ ) } l \in\{2,\ldots,\min(n,\lfloor K^d/55\rfloor)\} l ∈ { 2 , … , min ( n , ⌊ K d /55 ⌋)} are the same as us, and Γ δ \Gamma_\delta Γ δ is exactly the numerator in (29) .
In the first item case, let now take δ 0 : = e − 3 ∈ ( e − n , e − 2 ) \delta_0 := e^{-3} \in(e^{-n},e^{-2}) δ 0 := e − 3 ∈ ( e − n , e − 2 ) , together with n ≥ 110 n \ge110 n ≥ 110 . Corollary 3 gives μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}_l(\mathcal{X}_0) μ data ∈ P l ( X 0 ) with
P S ( KL ( μ d a t a ∣ ν ~ S ) ≥ l Λ l + 3 log K d 320 n ) ≥ e − 3 , \mathbb{P}_S\left(\operatorname{KL}(\mu_{\mathrm{data}}\mathbin| \widetilde{\nu}_S) \ge\frac{l\Lambda_l+3\log K^d}{320n}\right) \ge e^{-3}, P S ( KL ( μ data ∣ ν S ) ≥ 320 n l Λ l + 3 log K d ) ≥ e − 3 ,
hence, since Z ≥ a 1 { Z ≥ a } Z \ge a1\{Z \ge a\} Z ≥ a 1 { Z ≥ a } for Z ≥ 0 Z \ge0 Z ≥ 0 , we have
E S KL ( μ d a t a ∣ ν S ) ≥ E S KL ( μ d a t a ∣ ν ~ S ) ≥ e − 3 320 l Λ l n . \mathbb{E}_S\operatorname{KL}(\mu_{\mathrm{data}}\mathbin| \nu_S) \ge\mathbb{E}_S\operatorname{KL}(\mu_{\mathrm{data}}\mathbin| \widetilde{\nu}_S) \ge\frac{e^{-3}}{320}\frac{l\Lambda_l}{n}. E S KL ( μ data ∣ ν S ) ≥ E S KL ( μ data ∣ ν S ) ≥ 320 e − 3 n l Λ l .
On the other hand, for the second item, for δ ∈ ( e − min { n / 6 , K d } , e − 2 ) ⊆ ( e − n , e − 2 ) \delta\in(e^{-\min\{n/6,K^d\}},e^{-2}) \subseteq(e^{-n},e^{-2}) δ ∈ ( e − m i n { n /6 , K d } , e − 2 ) ⊆ ( e − n , e − 2 ) , Corollary 3 gives μ d a t a ∈ P l ( X 0 ) \mu_{\mathrm{data}} \in\mathcal{P}_l(\mathcal{X}_0) μ data ∈ P l ( X 0 ) with
P S ( KL ( μ d a t a ∣ ν ~ S ) ≥ Γ δ 320 n ) ≥ δ , \mathbb{P}_S\left(\operatorname{KL}(\mu_{\mathrm{data}}\mathbin| \widetilde{\nu}_S) \ge\frac{\Gamma_\delta}{320n}\right) \ge\delta, P S ( KL ( μ data ∣ ν S ) ≥ 320 n Γ δ ) ≥ δ ,
and KL ( μ d a t a ∣ ν S ) ≥ KL ( μ d a t a ∣ ν ~ S ) \operatorname{KL}(\mu_{\mathrm{data}}\mathbin| \nu_S) \ge\operatorname{KL}(\mu_{\mathrm{data}}\mathbin| \widetilde{\nu}_S) KL ( μ data ∣ ν S ) ≥ KL ( μ data ∣ ν S ) .
Both lower bounds hold with the universal constant c : = 1 320 e 3 c := \frac{1}{320e^3} c := 320 e 3 1 .
Proofs of Section 4
We first state precisely the mixed loss of Section 3.1 for a general kernel. Let μ 0 U : = P 0 , t Unif ( X 0 ) \mu_0^U:=P_{0,t}\operatorname{Unif}(\mathcal{X}_0) μ 0 U := P 0 , t Unif ( X 0 ) be the forward marginal starting from uniform data, let s ∗ U s_*^U s ∗ U be its score, defined as in (4) and L t U \mathcal{L}_t^U L t U the score-entropy loss. For γ > 0 \gamma>0 γ > 0 , the mixed loss interpolates between the empirical loss (8) and L t U \mathcal{L}_t^U L t U :
L ^ t M ( s ) : = n n + γ L ^ t ( s ) + γ n + γ L t U ( s ) . (68) \widehat{\mathcal{L}}_t^M(s):=\frac{n}{n+\gamma}\widehat{\mathcal{L}}_t(s)+\frac{\gamma}{n+\gamma}\mathcal{L}_t^U(s). \tag*{(68)} L t M ( s ) := n + γ n L t ( s ) + n + γ γ L t U ( s ) . (68)
Since the score-entropy loss is linear in the clean distribution and n n + γ μ 0 ( n ) + γ n + γ Unif ( X 0 ) = μ ^ 0 ( γ ) \frac{n}{n+\gamma}\mu_0^{(n)}+\frac{\gamma}{n+\gamma}\operatorname{Unif}(\mathcal{X}_0)=\widehat{\mu}_0^{(\gamma)} n + γ n μ 0 ( n ) + n + γ γ Unif ( X 0 ) = μ 0 ( γ ) , the mixed loss is, up to a constant, the score-entropy loss of μ ^ 0 ( γ ) \widehat{\mu}_0^{(\gamma)} μ 0 ( γ ) . The following lemma makes this precise.
Lemma 17. Let γ > 0 \gamma>0 γ > 0 , μ ^ t : = P 0 , t μ ^ 0 ( γ ) \widehat{\mu}_t:=P_{0,t}\widehat{\mu}_0^{(\gamma)} μ t := P 0 , t μ 0 ( γ ) and s ^ ( x , y , t ) : = μ ^ t ( x ) μ ^ t ( y ) \widehat{s}(x,y,t):=\frac{\widehat{\mu}_t(x)}{\widehat{\mu}_t(y)} s ( x , y , t ) := μ t ( y ) μ t ( x ) as in (24) . For every t ∈ ( 0 , T ] t\in(0,T] t ∈ ( 0 , T ] and every score s s s positive where Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 ,
L ^ t M ( s ) = ∑ y ∈ X μ ^ t ( y ) ∑ x ≠ y Q t ( y , x ) D ( s ^ ( x , y , t ) , s ( x , y , t ) ) + c t , \widehat{\mathcal{L}}_t^M(s)=\sum_{y\in\mathcal{X}}\widehat{\mu}_t(y)\sum_{x\ne y}Q_t(y,x)D\bigl(\widehat{s}(x,y,t),s(x,y,t)\bigr)+c_t, L t M ( s ) = y ∈ X ∑ μ t ( y ) x = y ∑ Q t ( y , x ) D ( s ( x , y , t ) , s ( x , y , t ) ) + c t , where c t ∈ R c_t\in\mathbb{R} c t ∈ R does not depend on s s s . In particular, s ^ \widehat{s} s minimizes s ↦ ∫ 0 T L ^ t M ( s ) d t s\mapsto\int_0^T\widehat{\mathcal{L}}_t^M(s)\,dt s ↦ ∫ 0 T L t M ( s ) d t , and a score s s s is another minimizer if and only if s ( x , y , t ) = s ^ ( x , y , t ) s(x,y,t)=\widehat{s}(x,y,t) s ( x , y , t ) = s ( x , y , t ) for almost every t ∈ ( 0 , T ] t\in(0,T] t ∈ ( 0 , T ] and every x ≠ y x\ne y x = y with $Q_t(y,x)>0.
Proof. Fix t ∈ ( 0 , T ] t\in(0,T] t ∈ ( 0 , T ] and a score s s s positive where Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 . Since Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 and ρ t ( y ) = 0 \rho_t(y)=0 ρ t ( y ) = 0 it must hold that ρ t ( x ) = 0 \rho_t(x)=0 ρ t ( x ) = 0 also. Moreover, since every state of X \mathcal{X} X can be reached from X 0 \mathcal{X}_0 X 0 , it follows that μ ^ 0 ( γ ) > 0 \widehat{\mu}_0^{(\gamma)}>0 μ 0 ( γ ) > 0 on X 0 \mathcal{X}_0 X 0 gives μ ^ t > 0 \widehat{\mu}_t>0 μ t > 0 on X \mathcal{X} X .
By (8) , averaging over the sample with μ t ( n ) = 1 n ∑ k P 0 , t ( ⋅ , X 0 ( k ) ) \mu_t^{(n)}=\frac{1}{n}\sum_k P_{0,t}(\cdot,X_0^{(k)}) μ t ( n ) = n 1 ∑ k P 0 , t ( ⋅ , X 0 ( k ) ) ,
L ^ t ( s ) = ∑ y ∑ x ≠ y Q t ( y , x ) ( μ t ( n ) ( y ) s − μ t ( n ) ( x ) log s ) . (69) \widehat{\mathcal{L}}_t(s)=\sum_y\sum_{x\ne y}Q_t(y,x)\left(\mu_t^{(n)}(y)s-\mu_t^{(n)}(x)\log s\right). \tag*{(69)} L t ( s ) = y ∑ x = y ∑ Q t ( y , x ) ( μ t ( n ) ( y ) s − μ t ( n ) ( x ) log s ) . (69)
Similarly, we have μ t U ( y ) s t U ( x , y , t ) = μ t U ( x ) \mu_t^U(y)s_t^U(x,y,t)=\mu_t^U(x) μ t U ( y ) s t U ( x , y , t ) = μ t U ( x ) whenever Q t ( y , x ) > 0 Q_t(y,x)>0 Q t ( y , x ) > 0 , so by (7),
L t U ( s ) = ∑ y ∑ x ≠ y Q t ( y , x ) ( μ t U ( y ) s − μ t U ( x ) log s ) + c t U , (70) \mathcal{L}_t^U(s)=\sum_y\sum_{x\ne y}Q_t(y,x)\left(\mu_t^U(y)s-\mu_t^U(x)\log s\right)+c_t^U, \tag*{(70)} L t U ( s ) = y ∑ x = y ∑ Q t ( y , x ) ( μ t U ( y ) s − μ t U ( x ) log s ) + c t U , (70)
c t U : = ∑ y μ t U ( y ) ∑ x ≠ y Q t ( y , x ) ϕ ( s t U ( x , y , t ) ) . c_t^U:=\sum_y\mu_t^U(y)\sum_{x\ne y}Q_t(y,x)\phi\left(s_t^U(x,y,t)\right). c t U := y ∑ μ t U ( y ) x = y ∑ Q t ( y , x ) ϕ ( s t U ( x , y , t ) ) .
Both expressions are linear in the measure, and n n + γ μ t ( n ) + γ n + γ μ t U = P 0 , t μ ^ 0 ( γ ) = μ ^ t \frac{n}{n+\gamma}\mu_t^{(n)}+\frac{\gamma}{n+\gamma}\mu_t^U=P_{0,t}\hat{\mu}_0^{(\gamma)}=\hat{\mu}_t n + γ n μ t ( n ) + n + γ γ μ t U = P 0 , t μ ^ 0 ( γ ) = μ ^ t by linearity of P 0 , t P_{0,t} P 0 , t . Hence, by (67),
L ^ t M ( s ) = ∑ y ∑ x ≠ y Q t ( y , x ) ( μ ^ t ( y ) s − μ ^ t ( x ) log s ) + γ n + γ c t U = ∑ y μ ^ t ( y ) ∑ x ≠ y Q t ( y , x ) ( s − s ^ log s ) + γ n + γ c t U , \begin{aligned}
\hat{\mathcal{L}}_t^M(s)=\sum_y\sum_{x\ne y}Q_t(y,x)\left(\hat{\mu}_t(y)s-\hat{\mu}_t(x)\log s\right)+\frac{\gamma}{n+\gamma}c_t^U \\
&=\sum_y\hat{\mu}_t(y)\sum_{x\ne y}Q_t(y,x)(s-\hat{s}\log s)+\frac{\gamma}{n+\gamma}c_t^U,
\end{aligned} L ^ t M ( s ) = y ∑ x = y ∑ Q t ( y , x ) ( μ ^ t ( y ) s − μ ^ t ( x ) log s ) + n + γ γ c t U = y ∑ μ ^ t ( y ) x = y ∑ Q t ( y , x ) ( s − s ^ log s ) + n + γ γ c t U ,
where we used μ ^ t ( x ) = μ ^ t ( y ) s ^ \hat{\mu}_t(x)=\hat{\mu}_t(y)\hat{s} μ ^ t ( x ) = μ ^ t ( y ) s ^ . Since s − s ^ log s = D ( s ^ , s ) − ϕ ( s ^ ) s-\hat{s}\log s=D(\hat{s},s)-\phi(\hat{s}) s − s ^ log s = D ( s ^ , s ) − ϕ ( s ^ ) by definition of D D D , this is the claimed identity with
c t : = γ n + γ c t U − ∑ y μ ^ t ( y ) ∑ x ≠ y Q t ( y , x ) ϕ ( s ^ ) . c_t:=\frac{\gamma}{n+\gamma}c_t^U-\sum_y\hat{\mu}_t(y)\sum_{x\ne y}Q_t(y,x)\phi(\hat{s}). c t := n + γ γ c t U − y ∑ μ ^ t ( y ) x = y ∑ Q t ( y , x ) ϕ ( s ^ ) .
Proof of Lemma 5. To begin this proof, we recall that the matrix Q 0 Q_0 Q 0 is in this case symmetric, so in particular P 0 , t P_{0,t} P 0 , t is doubly stochastic, in the sense that both columns and rows sum to 1. Furthermore, since the change of one token b 0 b_0 b 0 to b b b has probability 1 − α t K + α t 1 b = b 0 ≤ 1 K + α t \frac{1-\alpha_t}{K}+\alpha_t1_{b=b_0}\le\frac{1}{K}+\alpha_t K 1 − α t + α t 1 b = b 0 ≤ K 1 + α t , it follows that
P 0 , t ( x , x 0 ) ≤ 1 K d ( 1 + K α t ) d P_{0,t}(x,x_0)\le\frac{1}{K^d}(1+K\alpha_t)^d P 0 , t ( x , x 0 ) ≤ K d 1 ( 1 + K α t ) d
for all x , x 0 ∈ X 0 x,x_0\in\mathcal{X}_0 x , x 0 ∈ X 0 . Using now this inequality, we have that
μ T ( x ) = ∑ x 0 P 0 , T ( x , x 0 ) μ d a t a ( x 0 ) ≤ 1 K d ( 1 + K α T ) d , \mu_T(x)=\sum_{x_0}P_{0,T}(x,x_0)\mu_{\mathrm{data}}(x_0)\le\frac{1}{K^d}(1+K\alpha_T)^d, μ T ( x ) = x 0 ∑ P 0 , T ( x , x 0 ) μ data ( x 0 ) ≤ K d 1 ( 1 + K α T ) d ,
so
KL ( μ T ∣ Unif ( X 0 ) ) = ∑ x μ T ( x ) log ( K d μ T ( x ) ) ≤ d log ( 1 + K α T ) ≤ d K α T ≤ 1 n . (71) \operatorname{KL}(\mu_T\mid\operatorname{Unif}(\mathcal{X}_0))=\sum_x\mu_T(x)\log(K^d\mu_T(x))\le d\log(1+K\alpha_T)\le dK\alpha_T\le\frac{1}{n}. \tag*{(71)} KL ( μ T ∣ Unif ( X 0 )) = x ∑ μ T ( x ) log ( K d μ T ( x )) ≤ d log ( 1 + K α T ) ≤ d K α T ≤ n 1 . (71)
Notice that above we used that α T = e − σ ˉ T ≤ ( d K n ) − 1 \alpha_T=e^{-\bar{\sigma}T}\le(dKn)^{-1} α T = e − σ ˉ T ≤ ( d K n ) − 1 .
By Lemma 9, M γ − 1 ≤ s ^ ≤ M γ M_\gamma^{-1}\le\hat{s}\le M_\gamma M γ − 1 ≤ s ^ ≤ M γ on X 0 2 × [ 0 , T ] \mathcal{X}_0^2\times[0,T] X 0 2 × [ 0 , T ] with M = K d ( n + γ ) γ M=\frac{K^d(n+\gamma)}{\gamma} M = γ K d ( n + γ ) , and s ^ \hat{s} s ^ is continuous in t t t . Hence ∣ Q ^ u ( x , y ) ∣ ≤ M γ σ T − u max ∣ Q 0 ∣ |\hat{Q}_u(x,y)|\le M_\gamma\sigma_{T-u}\max|Q_0| ∣ Q ^ u ( x , y ) ∣ ≤ M γ σ T − u max ∣ Q 0 ∣ , which is integrable on [ 0 , T ] [0,T] [ 0 , T ] because we assumed σ ˉ T < ∞ \bar{\sigma}T<\infty σ ˉ T < ∞ . So, we have a unique absolutely continuous solution ( ν u ) u ∈ [ 0 , T ] (\nu_u)_{u\in[0,T]} ( ν u ) u ∈ [ 0 , T ] on the closed interval, ν ^ = ν T \hat{\nu}=\nu_T ν ^ = ν T , and ν ^ T − T 0 → ν T \hat{\nu}_{T-T_0}\to\nu_T ν ^ T − T 0 → ν T as T 0 ↓ 0 T_0\downarrow0 T 0 ↓ 0 by continuity. For every T 0 ∈ ( 0 , T ) T_0\in(0,T) T 0 ∈ ( 0 , T ) the hypotheses of Lemma 11 hold with μ ∞ = Unif ( X 0 ) > 0 \mu_\infty=\operatorname{Unif}(\mathcal{X}_0)>0 μ ∞ = Unif ( X 0 ) > 0 and s = s ^ s=\hat{s} s = s ^ , and Lemma 10 gives
∫ T 0 T L t ( s ^ ) d t ≤ KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) . \int_{T_0}^T\mathcal{L}_t(\hat{s})\,dt\le\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)}). ∫ T 0 T L t ( s ^ ) d t ≤ KL ( μ data ∣ μ ^ 0 ( γ ) ) .
Together with the bound KL ( μ T ∣ Unif ( X 0 ) ) ≤ 1 n \operatorname{KL}(\mu_T\mid\operatorname{Unif}(\mathcal{X}_0))\le\frac{1}{n} KL ( μ T ∣ Unif ( X 0 )) ≤ n 1 above, Lemma 11 yields
KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) + 1 n . (72) \operatorname{KL}(\mu_{T_0}\mid\nu_{T-T_0})\le\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)})+\frac{1}{n}. \tag*{(72)} KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ data ∣ μ ^ 0 ( γ ) ) + n 1 . (72)
Finally, μ T 0 = e σ ˉ T 0 Q 0 μ d a t a → μ d a t a \mu_{T_0} = e^{\bar{\sigma}_{T_0}Q_0}\mu_{\mathrm{data}} \to\mu_{\mathrm{data}} μ T 0 = e σ ˉ T 0 Q 0 μ data → μ data as T 0 ↓ 0 T_0 \downarrow0 T 0 ↓ 0 since σ ˉ T 0 → 0 \bar{\sigma}_{T_0} \to0 σ ˉ T 0 → 0 , and on a finite set ( μ , ν ) ↦ KL ( μ ∣ ν ) (\mu,\nu) \mapsto\operatorname{KL}(\mu\mid\nu) ( μ , ν ) ↦ KL ( μ ∣ ν ) is jointly lower semicontinuous, since it is a supremum of continuous functions by the Donsker–Varadhan formula KL ( μ ∣ ν ) = sup f { ∑ x f ( x ) μ ( x ) − log ∑ x e f ( x ) ν ( x ) } \operatorname{KL}(\mu\mid\nu) = \sup_f\{\sum_x f(x)\mu(x) - \log\sum_x e^{f(x)}\nu(x)\} KL ( μ ∣ ν ) = sup f { ∑ x f ( x ) μ ( x ) − log ∑ x e f ( x ) ν ( x )} . Hence
KL ( μ d a t a ∣ ν ^ ) ≤ lim inf T 0 ↓ 0 KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) + 1 n . \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu}) \le\liminf_{T_0\downarrow0}\operatorname{KL}(\mu_{T_0}\mid\nu_{T-T_0}) \le\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)}) + \frac{1}{n}. KL ( μ data ∣ ν ^ ) ≤ T 0 ↓ 0 lim inf KL ( μ T 0 ∣ ν T − T 0 ) ≤ KL ( μ data ∣ μ ^ 0 ( γ ) ) + n 1 .
Proof of Theorem 2. We start fixing a sample S S S ; γ ( S ) ∈ [ 1 , min { n , K d } ] \gamma(S) \in[1,\min\{n,K^d\}] γ ( S ) ∈ [ 1 , min { n , K d }] , μ ^ 0 ( γ ( S ) ) > 0 \hat{\mu}_0^{(\gamma(S))} > 0 μ ^ 0 ( γ ( S )) > 0 on X 0 \mathcal{X}_0 X 0 and s ^ \hat{s} s ^ its score. Thanks to Lemma 5, we know that
KL ( μ d a t a ∣ ν ^ ) ≤ KL ( μ d a t a ∣ μ ^ 0 ( γ ( S ) ) ) + 1 n . \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\nu}) \le\operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma(S))}) + \frac{1}{n}. KL ( μ data ∣ ν ^ ) ≤ KL ( μ data ∣ μ ^ 0 ( γ ( S )) ) + n 1 .
Taking expectations and using Lemma 2 gives the first item. Notice that C C C of Theorem 1 is replaced by C + 1 C+1 C + 1 here, because 1 n ≤ k e f f n \frac{1}{n} \le\frac{k_{\mathrm{eff}}}{n} n 1 ≤ n k eff , thanks to k e f f ≥ k e f f ( μ d a t a , 1 ) = 1 k_{\mathrm{eff}} \ge k_{\mathrm{eff}}(\mu_{\mathrm{data}},1) = 1 k eff ≥ k eff ( μ data , 1 ) = 1 for n ≥ 1 n \ge1 n ≥ 1 . Intersecting with the event A A A of Lemma 3, which does not depend on γ \gamma γ , gives the second item in the same way. Corollaries 1,2,4 then transfer perfectly, as recorded in their proofs.
Experiment details
All experiments use the masked kernel with α t = e − t \alpha_t = e^{-t} α t = e − t and κ t = α t / ( 1 − α t ) \kappa_t = \alpha_t/(1-\alpha_t) κ t = α t / ( 1 − α t ) . Seeds are fixed throughout.
Targets for label smoothing. We take K = 4 K = 4 K = 4 and d = 8 d = 8 d = 8 , so K d = 65,536 K^d = 65{,}536 K d = 65 , 536 . A 0 / 1 0/1 0/1 matrix A ∈ { 0 , 1 } K × K A \in\{0,1\}^{K\times K} A ∈ { 0 , 1 } K × K specifies the allowed token transitions. The first token is drawn from the stationary law of the chain, and each later token from the row-normalized weights, which are Dirichlet(2) on the allowed entries. The support is therefore exactly the set of length-d d d paths through A A A , and l = 1 ⊤ A d − 1 1 l = \mathbf{1}^{\top}A^{d-1}\mathbf{1} l = 1 ⊤ A d − 1 1 . We enumerate all 2 16 2^{16} 2 16 matrices and keep the 25,696 that are strongly connected and give every state at least one successor. For each target l ∈ { 16 , 64 , 256 , 1024 , 4096 } l \in\{16,64,256,1024,4096\} l ∈ { 16 , 64 , 256 , 1024 , 4096 } and each seed, we draw A A A uniformly among those with l l l within ± 5 % \pm5\% ± 5% of the target. We use n ∈ { 64 , 256 , 1024 } n \in\{64,256,1024\} n ∈ { 64 , 256 , 1024 } and 5 seeds, each seed fixes A A A , the weights and the sample, and the same sample is used for every γ \gamma γ .
Label-smoothed estimator. By Lemma 4, the masked sampler outputs exactly μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) . We therefore compute KL ( μ d a t a ∣ μ ^ 0 ( γ ) ) \operatorname{KL}(\mu_{\mathrm{data}}\mid\hat{\mu}_0^{(\gamma)}) KL ( μ data ∣ μ ^ 0 ( γ ) ) exactly by summing over V d \mathcal{V}^d V d , with no simulation.
Clipped empirical score. For the masked kernel, the estimator of Zhang et al. [19 ] reads s ^ t ( x , y ) = clip ( κ t ψ c ( n c ) ( a ) , ε , κ t ) \hat{s}_t(x,y) = \operatorname{clip}(\kappa_t\psi_c^{(n_c)}(a),\varepsilon,\kappa_t) s ^ t ( x , y ) = clip ( κ t ψ c ( n c ) ( a ) , ε , κ t ) , and we set s ^ t = ε \hat{s}_t = \varepsilon s ^ t = ε on unseen contexts (n c = 0 n_c = 0 n c = 0 ). Following their Theorem 3.8, we use early stopping at t 0 = 1 / n t_0 = 1/n t 0 = 1/ n , terminal time T = log n T = \log n T = log n , and ε = c 0 log n / n \varepsilon= c_0\log n/n ε = c 0 log n / n , with c 0 ∈ { 0.1 , 1 , 10 } c_0 \in\{0.1,1,10\} c 0 ∈ { 0.1 , 1 , 10 } chosen per ( l , n ) (l,n) ( l , n ) using the true KL.
Since the floor ε / κ t \varepsilon/\kappa_t ε / κ t depends on t t t , this score is improper, and the random-order sampler is not exact for it. We instead compute its output law by integrating the reverse Kolmogorov equation over all ( K + 1 ) d = 390,625 (K+1)^d = 390{,}625 ( K + 1 ) d = 390 , 625 partially masked states. We use RK4 on 400 log-spaced times from T T T to t 0 t_0 t 0 . Positions still masked at t 0 t_0 t 0 are unmasked one at a time in uniformly random order, with each token drawn with probability ∝ s ^ t 0 ( . , y ) \propto\hat{s}_{t_0}(.,y) ∝ s ^ t 0 ( . , y ) . As a check, running the same solver with the proper score κ t ψ ^ c \kappa_t\hat{\psi}_c κ t ψ ^ c reproduces μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) with a maximum relative error of 7.2 × 10 − 6 7.2 \times10^{-6} 7.2 × 1 0 − 6 .
Training. We use the sparse Markov chain of Zhang et al. [19 ] : K = 100 K = 100 K = 100 , d = 12 d = 12 d = 12 , 20 significant successors per state, ϵ b g = 0.01 \epsilon_{\mathrm{bg}} = 0.01 ϵ bg = 0.01 and p min = 10 − 3 p_{\min} = 10^{-3} p m i n = 1 0 − 3 . Held-out sequences are drawn fresh from the same chain. All training sequences are distinct, so D n = n D_n = n D n = n .
The model is their transformer (4 layers, width 128, 4 heads, ≈ 0.83 \approx0.83 ≈ 0.83 M parameters). We train it with AdamW (learning rate 5 × 10 − 4 5 \times10^{-4} 5 × 1 0 − 4 , β = ( 0.9 , 0.999 ) \beta= (0.9, 0.999) β = ( 0.9 , 0.999 ) , weight decay 10 − 3 10^{-3} 1 0 − 3 , batch size 128). To train on μ ^ 0 ( γ ) \hat{\mu}_0^{(\gamma)} μ ^ 0 ( γ ) , each sequence is replaced by a uniform element of V d V^d V d with probability p = γ / ( n + γ ) p = \gamma/(n+\gamma) p = γ / ( n + γ ) , for γ ∈ { 0 , 64 , 256 , 1024 , 4096 } \gamma\in\{0, 64, 256, 1024, 4096\} γ ∈ { 0 , 64 , 256 , 1024 , 4096 } and n ∈ { 1024 , 2896 , 8192 } n \in\{1024, 2896, 8192\} n ∈ { 1024 , 2896 , 8192 } . Each arm runs for ⌈ 6000 / ( 1 − p ) ⌉ \lceil6000/(1-p) \rceil ⌈ 6000/ ( 1 − p )⌉ iterations, so that all arms see the same expected number of real sequences. We evaluate the held-out NELBO at 40 log-spaced iterations starting at 10. Each of the 5 seeds fixes both the sample and the initialization.