---
title: 'SurrogateSHAP: A Surrogate-Based SHAP Framework'
url: https://www.emergentmind.com/topics/surrogateshap
type: topic
---

# SurrogateSHAP: A Surrogate-Based SHAP Framework

Searching arXiv for SurrogateSHAP and closely related surrogate-based SHAP papers.
SurrogateSHAP denotes a class of SHAP-oriented explanation methods in which a surrogate representation is used to make Shapley-style attribution computationally feasible, dependence-aware, or structurally interpretable. In the literature summarized here, the term refers most directly to a **surrogate model-based tree framework for computing Shapley values and SHAP values using conditional expectations** and to a **surrogate neural network** that learns conditional expectations under arbitrary feature subsets; closely related work uses surrogate trees for **prediction shifts** and tensor-network surrogates for graph-structured coalition games [2207.05214]. The common objective is not merely post hoc approximation of a prediction surface, but construction of a tractable engine for evaluating SHAP-relevant set functions such as conditional expectations, interventional means under subgroup conditionals, or masked coalition values [2307.10654].

## 1. Conceptual scope and historical positioning

The most direct use of the name **SurrogateSHAP** appears in work that fits a surrogate model to the fitted response \(\hat Y=f(X)\) and then uses that surrogate to approximate the conditional expectation needed by Shapley-style value functions [2207.05214]. In that formulation, the central problem is that both **global Shapley** and **local SHAP** require repeated evaluation of conditional expectations \(\mathbb{E}(f(X)\mid X_u)\) over many subsets \(u\subseteq K\), which is computationally expensive under feature dependence. The proposed remedy is to replace direct conditional-expectation computation by a structured surrogate, specifically a **SLIM tree** whose terminal nodes contain simple local models and whose path probabilities are estimated from data rather than treated as independent by default [2207.05214].

A second major line uses a **surrogate neural network** that learns, in one shot, the subset-conditioned expectation
\[
\mu_{\mathcal C}(x)=\left[\left.\mu(X)\right|X_{\mathcal C}=x_{\mathcal C}\right]
\]
for arbitrary \(\mathcal C\subseteq\mathcal Q\). This yields an efficient route to **conditional SHAP** for neural networks and other regression models while properly considering the dependence structure in the feature components [2307.10654].

Related work extends the surrogate principle beyond local prediction explanation. For explaining **prediction shifts** between two distributions \(P\) and \(Q\), a surrogate decision tree can be trained on black-box outputs over \(\mathcal P\cup\mathcal Q\), and Shapley values are then assigned to subgroup conditional probability changes induced by tree splits [2604.11200]. For graph-structured inputs, a compact tensor-network surrogate can approximate the coalition-value function \(\nu(S)\) and then support deterministic recovery of Shapley values and higher-order interaction indices from the learned multilinear extension [2606.01540].

This positioning also clarifies what SurrogateSHAP is not. DeepSHAP explains composite models by **propagating Shapley-style attributions through the internal components of a model stack** rather than by fitting a surrogate around the relevant value function, so it is a precursor in the Shapley-based explanation line rather than SurrogateSHAP itself [1911.11888]. Likewise, WOODELF is an **exact, model-specific SHAP/Banzhaf computation framework for decision trees and tree ensembles** and is explicitly not a surrogate-model method in the usual SurrogateSHAP sense [2511.09376].

## 2. Conditional-expectation foundations

A defining feature of SurrogateSHAP is its emphasis on conditional rather than purely marginal or path-independent semantics. In the surrogate model-based tree formulation, the Shapley coefficient for feature \(i\) is written as
\[
D_i = \sum_{u \subseteq K\setminus\{i\}} \frac{(p-|u|-1)!\,|u|!}{p!}\Big[c(u\cup\{i\})-c(u)\Big],
\]
with two value functions distinguished by interpretation regime: for **global Shapley**,
\[
c(u)=\operatorname{Var}\!\left(\mathbb{E}(f(X)\mid X_u)\right),
\]
and for **SHAP**,
\[
c(u)=\mathbb{E}(f(X)\mid X_u).
\]
The computational bottleneck is therefore the same in both settings: repeated estimation of \(\mathbb{E}(f(X)\mid X_u)\) when predictors are dependent [2207.05214].

The conditional expectation network formulation makes the same issue explicit for regression models. It contrasts **conditional SHAP**, based on
\[
\nu(\mathcal C)=\mu_{\mathcal C}(x)=\left[\left.\mu(X)\right|X_{\mathcal C}=x_{\mathcal C}\right],
\]
with the usual interventional approximation
\[
\nu(\mathcal C)=\left[\mu\!\left(X_{\mathcal Q\setminus \mathcal C}, x_{\mathcal C}\right)\right].
\]
The distinction matters because conditional SHAP respects the observed dependence structure among features, whereas unconditional SHAP breaks dependence by integrating over the marginal distribution of the missing features as if they were independent of the observed ones [2307.10654].

The conditional-expectation viewpoint also underlies criticisms of independence-based approximations. The surrogate model-based tree paper identifies a **path dependency issue** in Tree SHAP: splitting variables are treated as independent of other variables along the path, which can be inaccurate under correlation [2207.05214]. The conditional expectation network paper makes the complementary point that interventional SHAP can evaluate the model at feature combinations that may never occur in the data; its actuarial example states that unconditional SHAP can extrapolate into an unsupported region, while conditional SHAP remains aligned with the data-generating support [2307.10654].

A broader theoretical caution appears in work on aggregate SHAP for feature elimination. There, the standard global importance score
\[
\overline{\phi_i}(\mu,f)=\mathbb{E}_{x\sim \mu}\bigl[|\phi_i(\mu,f,x)|\bigr]
\]
is shown to be unsound for feature removal if computed only on the original data support. The proposed fix is to aggregate over the **extended distribution** \(\mu^*=\prod_{i=1}^d\mu_i^*\), the product of the marginals, under which small aggregate SHAP values do imply that a feature can be safely discarded [2503.23111]. This suggests that surrogate-based SHAP frameworks must be interpreted relative to the distributional semantics they approximate.

## 3. Surrogate constructions and computational mechanisms

Several distinct surrogate constructions appear in the literature, each tailored to a different SHAP-relevant object. The following summary is confined to the formulations explicitly described in the cited papers.

| Paper | Surrogate object | Target quantity |
|---|---|---|
| [2207.05214] | SLIM tree with local models | \(\mathbb{E}(\hat Y\mid X_u)\) |
| [2307.10654] | Masked-input neural network | \(\mu_{\mathcal C}(x)\) for all \(\mathcal C\) |
| [2604.11200] | Surrogate decision tree | Prediction shift \(\mu_Q-\mu_P\) via subgroup conditionals |
| [2606.01540] | Graph-aligned tensor network | Coalition-value function \(\nu(S)\) and multilinear extension |

In the **SLIM-tree** formulation, the key decomposition is
\[
\mathbb{E}(\hat Y\mid X_u)=\sum_{m=1}^M p(R_m\mid X_u)\,\mathbb{E}(\hat Y\mid R_m,X_u),
\]
where \(R_m\) is a terminal node event, \(p(R_m\mid X_u)\) is the path probability of reaching node \(m\) given the subset \(X_u\), and \(\mathbb{E}(\hat Y\mid R_m,X_u)\) is the local conditional expectation in that region [2207.05214]. If a splitting variable is in \(u\), the corresponding split probability is 1 once the instance is consistent with the split; if it is not in \(u\), the method rejects the usual independence assumption and instead fits a machine learning model locally to estimate
\[
p(A_i\mid A_1,\dots,A_{i-1},X_u)=\mathbb{E}(\mathbf{1}_{A_i}\mid A_1,\dots,A_{i-1},X_u).
\]
Within each terminal node, the local conditional expectation is taken to be additive,
\[
\mathbb{E}(\hat Y\mid R_m,X_u)=\beta_0+g_1(X_{k_1})+\cdots+g_{|u|}(X_{k_{|u|}}),
\]
with implementation using linear B-splines and weighted least squares [2207.05214].

The **conditional expectation network** uses masked inputs. For a mask vector \(m\) and subset \(\mathcal C\subseteq\mathcal Q\), the masked input is
\[
x_{\mathcal C}^{(m)}=\Big(m_1+(x_1-m_1)\mathbf 1_{\{1\in\mathcal C\}},\dots,m_q+(x_q-m_q)\mathbf 1_{\{q\in\mathcal C\}}\Big)^\top.
\]
A single neural network \(\mathrm{NN}_{\widehat\theta}\) is trained so that
\[
\mathrm{NN}_{\widehat\theta}\!\left(x_{\mathcal C}^{(m)}\right)\approx\mu_{\mathcal C}(x)
\]
for many \((x,\mathcal C)\) pairs [2307.10654]. The empirical risk is **triple-calibrated** through three classes of examples: original inputs with target \(\mu(x)\), fully masked inputs with target \(\mu_0\), and random partial masks with target \(\mu(x)\). This enforces recovery of the full model at \(x\) and the null model at full masking [2307.10654].

The **surrogate-tree method for prediction shifts** changes the target quantity. Given two distributions \(P\) and \(Q\), with
\[
\mu_P:=\mathbb{E}_{x\sim P}[f(x)],\qquad \mu_Q:=\mathbb{E}_{x\sim Q}[f(x)],
\]
the prediction shift is \(\mu_Q-\mu_P\). The surrogate tree is trained on black-box outputs over \(\mathcal D=\mathcal P\cup\mathcal Q\), but its impurity is not a standard predictive impurity. Instead, the proposed leaf impurity is
\[
I(l)\coloneqq \left(\frac{|\mathcal{P}_l|}{|\mathcal{P}|}+\frac{|\mathcal{Q}_l|}{|\mathcal{Q}|}\right)\times \left| \frac{\sum_{x\in\mathcal{P}_l} f(x)}{|\mathcal{P}_l|} - \frac{\sum_{x\in\mathcal{Q}_l} f(x)}{|\mathcal{Q}_l|} \right|,
\]
so that the tree is grown to minimize unexplained prediction shift rather than ordinary variance or Gini criteria [2604.11200].

The **tensor-network** formulation treats the full coalition table as a structured multilinear object. For masked graph inputs, the game value is
\[
\nu(S):=f(G,X_S),
\]
and the multilinear extension is
\[
\widetilde{\nu}(z)=\sum_{S \subseteq V} \nu(S) \prod_{v \in S} z_v \prod_{v \notin S}(1-z_v).
\]
A graph-aligned tensor network learns a surrogate \(\hat\nu(z;\Theta)\), after which Shapley values are recovered deterministically by
\[
\widehat{\phi}(u)=\int_0^1 \frac{\partial \hat{\nu}}{\partial z_u}(t\mathbf{1})\,dt.
\]
The paper’s “Gate Replacement Principle” states that differentiated variables are handled by replacing \(\bm b_u\) by \(\bm b_u'\) and contracting the tensor network as usual [2606.01540].

## 4. Relation to other SHAP approximation paradigms

SurrogateSHAP belongs to a broader family of SHAP approximations, but its mechanism is distinct from several neighboring lines of work. A useful contrast is with methods that fit surrogate regressions directly on coalition samples. KernelSHAP, LeverageSHAP, and PolySHAP solve weighted regression problems over sampled coalitions and then return the exact Shapley values of the surrogate approximation; OddSHAP refines this family by proving that the Shapley value depends exclusively on the **odd** component of the set function and by performing regression only on the odd subspace [2602.01399]. This is surrogate estimation in the regression-on-coalitions sense, whereas the SLIM-tree and conditional-expectation-network formulations use surrogates to approximate the conditional-expectation engine itself [2207.05214].

Another nearby line is the ensemble approximation of SHAP. ER-SHAP repeatedly samples random feature subspaces of size \(t\ll m\), computes “small” SHAP values on those subspaces, and averages them:
\[
\phi_i=\frac{1}{N_i}\sum_{k:i\in J_k}\phi_i^{(k)}.
\]
ERW-SHAP adds neighborhood generation and distance-based weights, while ER-SHAP-RF uses a random forest to define a feature-selection probability distribution [2103.03302]. These methods are explicitly described as surrogate SHAP-style local explanation strategies, but the proxy is an ensemble of many small SHAP computations rather than a single surrogate model [2103.03302].

DeepSHAP is related in philosophy but not in mechanism. It is presented as a framework for **layer wise propagation of Shapley values** that builds upon DeepLIFT, supports mixed model stacks such as a neural network feature extractor into a tree model, and justifies use of a background distribution by averaging single-reference SHAP values over background samples [1911.11888]. The essential operation is propagation of attributions through local components, not surrogate regression or surrogate conditional-expectation estimation.

The exact-computation literature also provides a contrast. WOODELF constructs pseudo-Boolean formulas for tree ensembles and computes Background SHAP, Path-Dependent SHAP, Shapley interaction values, Banzhaf values, and Banzhaf interaction values in a unified framework. It is explicitly positioned as an exact attribution engine rather than a surrogate explanation model [2511.09376]. This distinction matters because “surrogate” in SurrogateSHAP ordinarily refers to a learned intermediary whose fidelity and assumptions become part of the explanation semantics.

## 5. Empirical performance and reported use cases

The surrogate model-based tree paper reports simulation studies in **Linear**, **Nonlinear**, **Interaction**, and **Binary response** scenarios with correlations \(\rho\in\{0,0.2,0.4,0.5,0.75,0.9,0.99\}\), using \(20{,}000\) samples for estimation and an additional \(2{,}000\) for out-of-sample testing of the surrogate tree [2207.05214]. For global Shapley, the reported squared errors of the proposed **MBT** method are described as **very small**, often around \(10^{-4}\) to \(10^{-3}\), with examples including \(0.00020\), \(0.00032\), \(0.00068\), \(0.00253\), \(0.00164\), and \(0.00270\), whereas the marginal, empirical conditional, and M.A.SHAP baselines are substantially worse [2207.05214]. In the bike-sharing case study, the surrogate tree fitted to XGBoost predictions achieves training \(R^2 \approx 0.980\) and test \(R^2 \approx 0.982\), and the resulting global rankings broadly agree with permutation importance and Tree SHAP aggregation [2207.05214].

The conditional expectation network paper emphasizes computational reuse rather than a single headline metric. One surrogate network can be used for **conditional SHAP**, **drop1**, **anova**, **MCEP**, and **loss attribution**, thereby avoiding both fitting \(2^q\) separate models and nested conditional Monte Carlo for every subset [2307.10654]. In the actuarial motor insurance example, it reports that the surrogate reproduces both full and null model losses well and that conditional SHAP gives sensible explanations in settings where unconditional SHAP can overstate importance for variables whose combinations are out of support [2307.10654].

For distribution shift explanation, the surrogate-tree variant shows a sharp reduction in incompleteness when trained with the proposed impurity objective. On Pima Indians Diabetes with 10-leaf surrogates, the paper reports **about \(73\%\) unexplained** for a naive surrogate and **about \(8.1\%\) unexplained** for the optimized surrogate, where
\[
\text{PercentUnexplained}\coloneqq 100\times \frac{|\phi_{\text{LeafMeans}}|}{|\mu_Q-\mu_P|}.
\]
Across 250 real distribution shifts over five Folktables tasks, the method is reported to run efficiently, usually achieve low unexplained shift, produce parsimonious explanations with a few dominant subgroup conditionals, and exhibit median **R-Faithfulness** above \(0.998\) for all model classes, including neural networks with surrogates [2604.11200].

For graph-structured inputs, TN-SHAP-G reports extremely close agreement with exact Shapley values on small molecular graphs: on Benzene, **O1 cosine \(0.9979\)** and **O2 cosine \(0.9612\)**; on Mutagenicity, **O1 cosine \(0.9933\)** and **O2 cosine \(0.9688\)** [2606.01540]. Against sampling-based estimators such as permutation sampling and SHAP-IQ, it is reported to reach about \(0.95\) cosine similarity with roughly \(10\)–\(100\times\) fewer model queries, and on PROTEINS it maintains test \(R^2>0.8\) across graphs up to 600 nodes with Shapley efficiency gaps on the order of \(10^{-7}\) to \(10^{-5}\) [2606.01540]. This suggests that surrogate-based SHAP is not confined to tabular local explanation, but can serve as an amortized attribution engine in structured domains.

## 6. Assumptions, limitations, and interpretive issues

The main limitations of SurrogateSHAP are tied to what the surrogate is assumed to approximate. In the SLIM-tree framework, three assumptions are explicit: only the **top important variables** are used in each split node to compute path probabilities; the local conditional expectation in each terminal node is **additive**; and thresholding ignores unselected subsets, improving speed at the cost of accuracy [2207.05214]. The thresholded subset family
\[
D=\{u\subseteq K:\ |u|\le y \ \text{or}\ |u|\ge p-y\}
\]
is justified by the Shapley weight structure, but the paper notes that stronger feature correlation generally requires larger \(y\), and even \(y=2\) can leave about 10,000 subsets when \(p=100\) [2207.05214].

The conditional expectation network introduces a different set of design constraints. Its calibration requires careful mask selection, ideally satisfying \(\mu(m)=\mu_0\), and the training data are synthetically expanded through full masking and random partial masking [2307.10654]. This suggests that fidelity depends not only on network capacity but also on whether the mask state yields a stable and non-conflicting representation of “missingness.” The paper also frames the surrogate as a regularized proxy, which is useful computationally but means that explanation faithfulness remains mediated by surrogate fit [2307.10654].

In the shift-explanation setting, the surrogate is only an approximation to the black-box model, so the decomposition is explicitly augmented by a residual factor \(\phi_{\text{LeafMeans}}\) and evaluated through **PercentUnexplained** [2604.11200]. That residual is not a peripheral quantity; it is the completeness diagnostic that determines whether the subgroup-conditional explanation is near-complete or only partial.

A recurrent misconception is that any SHAP-based approximation is interchangeable with SurrogateSHAP. The literature summarized here does not support that equivalence. DeepSHAP uses propagation, ER-SHAP uses ensembles of small SHAP runs, OddSHAP uses odd-subspace regression, and WOODELF is exact on tree ensembles rather than surrogate-based [1911.11888]. Another misconception is that aggregate SHAP values can always justify feature removal. The safe-discarding results show that this is false on the original support and only becomes theoretically sound when the aggregation is performed over the extended distribution \(\mu^*\) or a scrambled sample approximating it [2503.23111].

Taken together, these constraints indicate that SurrogateSHAP is best understood not as a single algorithm but as a surrogate-centered design pattern for SHAP computation. This suggests a unifying principle: the quality of the explanation is determined by how faithfully the surrogate captures the specific SHAP-relevant object—conditional expectations, subgroup interventional means, or coalition-value functions—rather than by surrogate accuracy in an undifferentiated predictive sense.

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