---
title: 'Adalina: Adaptive Linear Approximation'
url: https://www.emergentmind.com/topics/adalina
type: topic
---

# Adalina: Adaptive Linear Approximation

Searching arXiv for the specified Adalina paper and closely related semi-value approximation work.
arXiv search query: 2604.08438 OR "Provably Adaptive Linear Approximation for the Shapley Value and Beyond"
Adalina, short for **Adaptive Linear Approximation**, is a randomized algorithm for approximating the Shapley value and more general semi-values under a $\Theta(n)$ memory constraint. It is introduced in “Provably Adaptive Linear Approximation for the Shapley Value and Beyond” [2604.08438] as the first adaptive, linear-time, linear-space randomized algorithm that provably improves mean square error while retaining the sharp query-complexity guarantees established in the same framework. The method operates in the standard utility-query model for cooperative games and attribution problems, where exact semi-value computation is exponential in the number of players $n$, and it is designed to make approximation theoretically precise in both query complexity and MSE.

## 1. Problem formulation and semi-value setting

The underlying object is a utility function $U: 2^{[n]} \to \mathbb{R}$ that assigns a scalar utility to every coalition $S \subseteq [n]$. In attribution settings, the players may be features or data points, and a utility query evaluates $U(S)$ for a chosen subset. Exact semi-value computation is exponential in $n$ because it aggregates marginal contributions $U(S \cup \{i\}) - U(S)$ across all eligible subsets [2604.08438].

For the Shapley value, the paper uses
$$
\phi_i = \sum_{S \subseteq N \setminus \{i\}} w(S)\,[v(S \cup \{i\}) - v(S)],
$$
with
$$
w(S) = \frac{|S|!(n-|S|-1)!}{n!}.
$$

More generally, it adopts the Dubey–Neyman–Weber representation of semi-values. For a Borel probability measure $\mu$ on $[0,1]$, define
$$
p_s = \int_0^1 t^{s-1}(1-t)^{n-s}\, d\mu(t), \qquad s=1,\dots,n.
$$
Then
$$
\phi_i(U) = \sum_{S \subseteq [n]\setminus\{i\}} p_{|S|+1}\,[U(S \cup \{i\}) - U(S)].
$$
When $\mu$ is uniform, this recovers the Shapley value with
$$
p_s = \frac{1}{n}\binom{n-1}{s-1}^{-1}.
$$
The same representation covers Beta Shapley values and weighted Banzhaf values.

The paper specifically targets the **linear-space regime**. With $T$ utility queries, it establishes that
$$
P(\|\hat{\boldsymbol\phi}-\boldsymbol\phi\|_2 \ge \epsilon)\le \delta
$$
once
$$
T \ge \frac{4 n D^* C^2}{\epsilon^2}\log\frac{2}{\delta},
$$
where $|U(S)| \le C$ and $D^*$ is a semi-value–dependent constant satisfying $D^* \in O(1)$ for Beta Shapley and weighted Banzhaf.

## 2. Dimension-free concentration and optimal size sampling

A central contribution of the framework is a dimension-free vector concentration inequality applied directly to the full estimation-error vector rather than coordinatewise bounds with a union bound [2604.08438]. The theorem states that if $X_1,\dots,X_M$ are i.i.d. zero-mean random vectors with
$$
E[\|X_i\|_2^2]\le \sigma^2, \qquad \|X_i\|_2 \le C \text{ almost surely},
$$
then for every $0 < \epsilon \le 3\sigma^2/C$,
$$
P\!\left(\left\|\frac{1}{M}\sum_{i=1}^M X_i\right\|_2 \ge \epsilon\right)
\le 2\exp\!\left(-\frac{M\epsilon^2}{4\sigma^2}\right).
$$
The significance of this step is that it avoids the extra $\log n$ factor that arises from coordinatewise concentration plus union bounds.

The semi-value vector is decomposed as
$$
\phi = \varphi + (p_n u_{[n]} - p_1 u_{\emptyset})\cdot 1_n,
$$
where $\varphi$ aggregates the interior coalitions with $1 \le |S| \le n-1$ and $u_S := U(S)$. To estimate $\varphi$, the framework samples coalition sizes $s \in \{1,\dots,n-1\}$ with probabilities $q_s$, then samples $S$ uniformly among size-$s$ subsets. Writing
$$
m_s := \binom{n-1}{s-1} p_s,
$$
the estimator uses
$$
(z_S)_i = \frac{n}{q_s}\left(\frac{m_s}{s}\mathbf{1}\{i \in S\} - \frac{m_{s+1}}{n-s}\mathbf{1}\{i \notin S\}\right).
$$
The resulting unbiased estimator is
$$
\hat{\phi} = \frac{1}{T}\sum_{t=1}^T u_{S_t} z_{S_t} + (m_n u_{[n]} - m_1 u_{\emptyset})\cdot 1_n.
$$

The framework isolates a quantity
$$
D(q) = \sum_{s=1}^{n-1} \frac{n}{q_s}\left(\frac{m_s^2}{s} + \frac{m_{s+1}^2}{n-s}\right),
$$
which governs query complexity, and shows that the optimal size distribution is uniquely
$$
q_s^* \propto \sqrt{\,n\left(\frac{m_s^2}{s}+\frac{m_{s+1}^2}{n-s}\right)}.
$$
The corresponding optimum is
$$
D^* = \left(\sum_{s=1}^{n-1}\sqrt{\,n\left(\frac{m_s^2}{s}+\frac{m_{s+1}^2}{n-s}\right)}\right)^2.
$$
For Shapley, this yields
$$
q_s^* \propto \frac{1}{\sqrt{s(n-s)}}.
$$

An important structural consequence is the paper’s decoupling of **query complexity** from **MSE**: the tail bound depends on $D(q)$, whereas the MSE depends on the second moment of the sampled utility values under an induced distribution $\tilde q$.

## 3. Adalina as an adaptive control-variate estimator

Adalina is built on the observation that $\phi(\text{constant } U)=0$, so one may subtract a constant $\gamma$ from sampled utilities without introducing bias [2604.08438]. This gives the estimator
$$
\hat{\phi}^{\gamma} := \frac{1}{T}\sum_{t=1}^T (u_{S_t}-\gamma) z_{S_t} + b,
$$
where
$$
b = [m_n(u_{[n]}-\gamma) - m_1(u_{\emptyset}-\gamma)]\cdot 1_n.
$$
For symmetric semi-values, where $m_1 = m_n$, the endpoint term collapses to the original endpoint correction, so only the centered quantity $u_S-\gamma$ changes.

The MSE of this centered estimator is
$$
E[\|\hat{\phi}^{\gamma}-\phi\|_2^2]
=
\frac{nD^*E[(u_S-\gamma)^2]-\|\varphi\|_2^2}{T},
$$
so the optimal constant is
$$
\gamma^* = E[u_S],
$$
with expectation taken under the same optimal sampler. This is the key adaptive idea: the optimal control variate can be estimated “for free” from the same sequence of samples used to estimate $\phi$.

The algorithm maintains three length-$n$ vectors, or equivalently two vectors plus a scalar: $\hat{\varphi}$, $\hat v$, and $\hat\gamma$. For $t=1,\dots,T$, it draws $s \sim q^*$, samples $S \subset [n]$ uniformly with $|S|=s$, computes $z_S$, and performs running-average updates
$$
\hat{\varphi} \leftarrow \left(1-\frac{1}{t}\right)\hat{\varphi} + \frac{1}{t}u_S z_S,
$$
$$
\hat v \leftarrow \left(1-\frac{1}{t}\right)\hat v + \frac{1}{t} z_S,
$$
$$
\hat\gamma \leftarrow \left(1-\frac{1}{t}\right)\hat\gamma + \frac{1}{t}u_S.
$$
The output is
$$
\hat{\phi}^{\text{Adalina}}
=
\hat{\varphi} - \hat\gamma \hat v
+ m_n(u_{[n]}-\hat\gamma)\cdot 1_n
- m_1(u_{\emptyset}-\hat\gamma)\cdot 1_n.
$$

The resource profile is explicit. Memory is $\Theta(n)$, per-sample time is $O(n)$ because all $n$ coordinates are updated using the membership test $i \in S$, and total time is $O(Tn)$.

## 4. Guarantees, optimality, and the Adalina-All variant

For symmetric semi-values, Adalina provably approaches the best constant-control-variate estimator while preserving the same optimal query complexity [2604.08438]. Its finite-sample bound is
$$
E[\|\hat{\phi}^{\text{Adalina}}-\phi\|_2^2]
\le
\frac{1}{T}\left(nD^*E[(u_S-\gamma^*)^2]-\|\varphi\|_2^2\right)
+
\frac{6nD^*\|U\|_\infty^2}{T(T-1)}.
$$
Equivalently, its MSE equals the optimal constant-control-variates MSE up to an $O(n/T^2)$ term.

The corresponding tail bound under $q=q^*$ is
$$
P(\|\hat{\phi}-\phi\|_2 \ge \epsilon)
\le
2\exp\!\left(-\frac{T\epsilon^2}{4nD^*C^2}\right),
$$
valid for sufficiently small $\epsilon$. The baseline, non-adaptive MSE is
$$
E[\|\hat{\phi}-\phi\|_2^2]
=
\frac{nD^*E[u_S^2]-\|\varphi\|_2^2}{T},
$$
whereas centering with the optimal $\gamma^*$ replaces $E[u_S^2]$ by $E[(u_S-\gamma^*)^2]$.

For general semi-values, the simplest Adalina proof requires symmetry only because it uses $m_1 = m_n$. The paper therefore introduces **Adalina-All**, based on an MSR-style sampler that includes $s=0$ and $s=n$, and states that this variant recovers the same MSE-improvement phenomenon without requiring $m_1 = m_n$.

A notable claim of the framework is a **definitive optimality statement** for the size sampler: for fixed semi-value weights $\{m_s\}$, $q^*$ is the unique minimizer of $D(q)$ and therefore uniquely minimizes query complexity within this framework. This makes the adaptivity of Adalina an MSE refinement layered on top of an already query-optimal estimator.

## 5. Paired sampling and unification of prior estimators

The framework gives a precise criterion for when paired sampling helps [2604.08438]. In the paired scheme, after sampling $S$, one also evaluates its complement $S^c$, using two queries per matched pair. For symmetric semi-values and symmetric size samplers with $q_s=q_{n-s}$, the paper shows that this is equivalent to estimating $(U-U^c)/2$, where $U^c(S)=U([n]\setminus S)$.

Under this setup, the MSE becomes
$$
E[\|\hat{\phi}-\phi\|_2^2]
=
\frac{nD(q)\sigma_{\tilde q}^2 - 2\|\varphi\|_2^2}{T},
$$
with
$$
\sigma_{\tilde q}^2 = E_{\tilde q}[u_S^2] - E_{\tilde q}[u_Su_{S^c}].
$$
Hence paired sampling is beneficial if and only if
$$
E_{\tilde q}[u_Su_{S^c}] > 0.
$$
The paper notes that this holds, for example, when $U$ has a fixed sign, and also emphasizes that paired sampling can hurt when the condition fails.

The same framework is presented as a bridge across several existing estimators. OFA is shown to use the same optimal size weights $q^*$ but with $\Theta(n^2)$ stored statistics in its original form; the new analysis gives a linear-space unbiased counterpart with the sharper vector-concentration tail behavior. For Shapley, the framework recovers unbiased kernelSHAP, and specifically identifies the modified unbiased kernelSHAP sampler as exactly $q^*$. It contrasts this with vanilla kernelSHAP and leverage-score kernelSHAP, which incur an extra $\log n$ in query complexity. It similarly states that SHAP-IQ uses a non-optimal sampler $q_s \propto 1/[s(n-s)]$ and that replacing it by $q^*$ improves the tail bound. The regression-adjusted Monte Carlo estimators denoted MSR are described as using an extended $q^*$ over $s=0,\dots,n$; this gives the same linear-space, linear-time, optimal-query behavior and underlies Adalina-All.

For the Shapley case, the framework also generalizes the usual kernelSHAP centering trick. If $V(S)=f(|S|)$, then $E[v_S z_S]=0$, so one may subtract any function of $s$ without bias. The paper explicitly notes that subtracting $\lambda s$ is only a special case of this more general invariance.

## 6. Empirical evaluation, practical use, and limitations

The empirical study uses feature-attribution utilities $U_f^x(S)$ with tree-based models on six OpenML datasets—spambase, FOTP, Miniboone, philippine, GPSP, and superconduct—with numbers of features ranging from $32$ to $308$ [2604.08438]. Because exact semi-values are available in polynomial time for trees, empirical approximation errors can be measured against ground truth. Relative $L_2$ error versus query budget, up to $1000$ queries per feature, is compared against linear-space baselines including MSR-Banzhaf, MSR-Prob, SHAP-IQ, unbiased kernelSHAP, AME/ARM, and GELS/GELS-Shapley.

The reported findings are threefold. First, the modified unbiased kernelSHAP using $q^*$ matches the query-optimal guarantee and outperforms vanilla and leverage-score kernelSHAP. Second, paired sampling helps exactly when $E_{\tilde q}[U(S)U(S^c)]>0$ and can otherwise degrade MSE. Third, Adalina consistently reduces MSE relative to its non-adaptive counterpart and approaches the optimal constant-control-variates MSE while keeping the same tail guarantee and $\Theta(n)$ memory. For non-symmetric semi-values, Adalina-All exhibits the same improvement trend.

The practical guidance given by the paper is correspondingly specific. For symmetric semi-values such as Shapley and Banzhaf, Adalina with $q^*$ is the recommended choice because it combines optimal query complexity with MSE improvement. For general semi-values, the recommendation is Adalina-All with MSR sampling over all coalition sizes including $\emptyset$ and $[n]$. For paired sampling, the paper advises turning it on when the utility is mostly nonnegative or mostly nonpositive, so that the positivity criterion is likely satisfied. Runtime can be targeted through
$$
T \approx \frac{4 n D^* C^2}{\epsilon^2}\log\frac{2}{\delta},
$$
and if $C$ is unknown, sample ranges of $u_S$ may be monitored to upper bound it.

The scope and limitations are also explicit. The analysis assumes bounded utilities, independent sampling of sizes and subsets, and i.i.d. sample terms for concentration. If $U$ changes sign frequently, paired sampling can degrade MSE. For Shapley, subtracting a function such as $\lambda s$ or more general $f(s)$ can in principle outperform subtracting a constant $\gamma$, whereas Adalina currently optimizes only the constant control variate. Finally, although each sample costs only $O(n)$ time, combining this with the stated query budget implies total work of $\Theta(n^2/\epsilon^2 \cdot \log(1/\delta))$ when $T$ is chosen at the concentration scale. This suggests that Adalina’s principal contribution is not sublinear runtime, but a sharpened statistical-computational tradeoff in the linear-space regime.

Source: https://www.emergentmind.com/topics/adalina