---
title: ShapKAN in Kolmogorov–Arnold Networks
url: https://www.emergentmind.com/topics/shapkan
type: topic
---

# ShapKAN in Kolmogorov–Arnold Networks

Searching arXiv for recent papers on “ShapKAN” and closely related KAN work.
ShapKAN is a term used in the Kolmogorov–Arnold Network literature for distinct, non-equivalent constructions built on the same architectural premise: learnable univariate functions placed on edges rather than fixed nonlinearities placed on nodes. In its most specific usage, ShapKAN denotes a pruning and attribution framework for Kolmogorov–Arnold Networks that uses Shapley value scoring to quantify true node contributions in a shift-invariant manner, thereby addressing a central failure mode of magnitude-based pruning in spline-parameterized KANs [2510.01663]. The term has also been used for a shape-centric convolutional KAN in which learnable univariate functions parameterize filter shape rather than act on every kernel entry [2606.24371], and for a shape-parameter-adaptive RBF-KAN that learns radial kernel scale parameters with LOOCV initialization [2605.21534]. All of these usages presuppose the KAN formalism introduced as an alternative to MLPs, where the basic computational units are edge-wise univariate functions and node-wise summation [2404.19756].

## 1. KAN substrate and the interpretability setting

Kolmogorov–Arnold Networks are motivated by the Kolmogorov–Arnold representation theorem, presented in the KAN literature in the form
$$
f(x_1,\dots,x_n)=\sum_{q=1}^{2n+1}\Phi_q\!\Big(\sum_{p=1}^n\phi_{q,p}(x_p)\Big),
$$
with continuous univariate inner functions $\phi_{q,p}$ and outer functions $\Phi_q$ [2404.19756]. KANs implement this idea by placing trainable univariate activation functions on edges and summing at nodes. A standard KAN layer computes
$$
x_{l+1,k} = \sum_{i=1}^{n_l} \phi_{l,k,i}(x_{l,i}),
$$
equivalently
$$
y^{(l)}_k = \sum_{j=1}^{n_l} \phi^{(l)}_{k,j}(x^{(l)}_j),
$$
and an $L$-layer network composes layer operators as
$$
KAN(x) = (\Phi_{L-1} \circ \Phi_{L-2} \circ \cdots \circ \Phi_0)(x)
$$
[2510.01663].

In the spline-based formulation, each edge activation is parameterized as
$$
\phi_{l,k,i}(z) = \sum_{p=1}^{P_l} c^{(l,k,i)}_{p} B^{(l)}_{p}(z),
$$
where $\{B^{(l)}_{p}\}$ are B-spline basis functions of fixed order, such as cubic splines, on a chosen grid, and $c^{(l,k,i)}_{p}$ are coefficients [2510.01663]. The original KAN formulation also uses a residual base function, with
$$
\phi(x)=w_b\,b(x)+w_s\,\mathrm{spline}(x),
$$
and $b(x)=\mathrm{silu}(x)$ for stability [2404.19756]. This edge-local parameterization is the fundamental unit in KANs rather than scalar weights.

Interpretability in KANs is closely tied to sparsification and post-training simplification. A typical training objective augments the prediction loss with sparsity-inducing penalties,
$$
L = L_{\mathrm{pred}} + \lambda\Big( \mu_1 \sum_{l=0}^{L-1} ||\Phi_l||_1 + \mu_2 \sum_{l=0}^{L-1} ||S(\Phi_l)|| \Big),
$$
where $||\Phi_l||_1$ aggregates $L1$ norms over edge activations and $S(\Phi_l)$ is an entropy-like sparsity transform [2510.01663]. In the original KAN work, this regularization underpins pruning and symbolification, and smaller KANs tend to yield simpler symbolic forms and better generalization [2404.19756]. ShapKAN in the Shapley-based sense arises precisely because this standard magnitude-centric simplification pipeline becomes unstable under input reparameterization.

## 2. ShapKAN as a Shapley-based pruning and attribution framework

In "Shift-Invariant Attribute Scoring for Kolmogorov-Arnold Networks via Shapley Value" [2510.01663], ShapKAN formalizes each hidden layer as a cooperative game whose players are neurons. For a layer $l$ with nodes $L_l=\{x_{l,i}: i \in N_l\}$ and coalitions $S_{L_l}\subseteq L_l$, the value function is defined by the prediction game
$$
v(S_{L_l}) = E_{x\sim D}[KAN_{S_{L_l}}(x)],
$$
where $KAN_{S_{L_l}}$ computes the network output with the layer-$l$ node set restricted to $S_{L_l}$, namely
$$
x_{l+1,j} = \sum_{i \in S_l} \phi_{l,j,i}(x_{l,i}),
$$
while the rest of the forward graph is unchanged. The game is layer-local, but contributions propagate through the composed network.

For a player $i$ in a player set $N$, the Shapley value is
$$
\phi_i(v) = \sum_{S \subseteq N \setminus \{i\}} \frac{|S|!(|N|-|S|-1)!}{|N|!}\,\big(v(S \cup \{i\}) - v(S)\big).
$$
The same paper gives an equivalent sampling form,
$$
Shap(i) = \frac{1}{|D|} \sum_{S \subseteq D\setminus\{i\}} \Bigg[ \binom{|D|-1}{|S|}^{-1} \big( v(S\cup\{i\}) - v(S) \big) \Bigg].
$$
ShapKAN computes Shapley values per layer with $v$ defined as above and aggregates over a dataset by empirical averaging, using batching in practice [2510.01663].

The resulting neuron-level importance score is
$$
I^{(l)}_i := Shap(x_{l,i}; v_l, D),
$$
estimated by permutation sampling on batches of data. These scores are then used in a bottom-up layer-wise pruning policy. For each layer, the framework computes exact or approximate Shapley values for all neurons, ranks neurons by absolute Shapley scores, and prunes them by one of three criteria: ratio pruning, number pruning, or threshold pruning. Ratio pruning removes neurons with Shapley below a fraction $\eta$ of the total layer contribution; number pruning removes the $k$ lowest-Shapley neurons; threshold pruning removes neurons with $Shapley < \tau$. After pruning, the model is updated by removing nodes and incident edges before proceeding to the next layer [2510.01663].

A key implementation restriction is explicit: ShapKAN avoids feature-level Shapley at the input layer because that would require modeling conditional input distributions. The framework is therefore a node-level attribution and pruning method internal to KAN layers rather than a generic feature explainer [2510.01663].

## 3. Shift invariance and the failure of magnitude-based pruning

The central technical claim of ShapKAN is that Shapley-based neuron attribution is robust to affine reparameterizations that preserve the represented function, whereas magnitude-based scores are not. In vanilla KAN pruning, node importance is derived from edge norms, for example
$$
I_{l,i} = \max_k ||\phi_{l-1,i,k}||_1,\qquad O_{l,i} = \max_j ||\phi_{l,i,j}||_1,
$$
and nodes are removed if $I_{l,i}, O_{l,i} < \theta$ with $\theta \approx 1e^{-2}$ [2510.01663]. Because KANs use edge-wise splines, the magnitudes of spline coefficients and cached activations change under input-domain shifts such as moving from $[-1,1]$ to $[0,1]$ or $[-1,0]$, even when the represented function is unchanged. The paper identifies this as a source of inconsistent importance rankings, unstable pruning, and degraded interpretability.

The formal invariance statement is given as an affine reparameterization result. If an incoming activation is reparameterized by $z \mapsto az+b$ and the edge functions are compensatingly reparameterized so that the overall network output $f(x)$ is unchanged for all $x$, then for any coalition $S$ at layer $l$, the value $v(S)=E[f_S(x)]$ is unchanged; therefore all marginal differences $v(S\cup\{i\})-v(S)$ are unchanged and the Shapley values remain invariant. By contrast, magnitude-based scores such as $||\phi_{l,k,i}||_1$ depend on the coefficients of the reparameterized spline basis and can change under $z \mapsto az+b$, altering rankings [2510.01663].

This invariance argument is operational rather than merely axiomatic. ShapKAN’s attributions depend on output-level marginal gains measured through the value function, not on internal coefficient magnitudes. The paper further states that the layer-local Shapley values satisfy dummy, efficiency, and symmetry axioms, which is used to justify them as fair attributions of node importance [2510.01663].

The comparison to other explainability methods is also structurally specific. Integrated Gradients, LRP, and DeepSHAP are described as feature-level explainers that require conditional modeling or linearization assumptions and do not naturally handle KAN’s node-level, edge-wise functional units. KernelSHAP and amortized explainers can estimate Shapley values, but they rely on additional assumptions such as linear constraints or an auxiliary black box. ShapKAN instead uses unbiased permutation sampling, layer-local games, and direct value-function measurements [2510.01663]. This suggests that the method is designed less as a replacement for feature attribution and more as a structurally matched pruning criterion for spline-based KANs.

## 4. Estimation, pruning workflow, and empirical behavior

Exact Shapley evaluation scales as $O(n \cdot 2^n)$ per layer and is therefore infeasible for wide layers. ShapKAN uses unbiased permutation sampling,
$$
\widehat{Shap}(x_{l,i}) = \frac{1}{m}\sum_{t=1}^{m}\Big[v(S^{(t)}_{L_l}\cup\{x_{l,i}\}) - v(S^{(t)}_{L_l})\Big],
$$
where $S^{(t)}$ is the set of predecessors of $i$ in a random permutation of $N_l$, with convergence rate $O(1/\sqrt{m})$ [2510.01663]. Variance is reduced by antithetic sampling, which pairs each permutation with its reverse. For small layers, such as $n_l<8$, exact Shapley is computed.

On synthetic tasks, the reported setup uses functions
$f_1(x_1,x_2)=x_1x_2$,
$f_2(x_1,x_2)=\exp(J_0(20x_1)+x_2^2)$,
$f_3(x_1,x_2,x_3)=\tanh(5(\sum_i x_i^4-1))$,
and
$f_4(x_1,x_2)=\exp(\sin(\pi x_1)+x_2^2)$,
with architecture $[d,5,1]$, cubic B-spline edge activations, LBFGS optimization, grids of $3$ or $5$ per task, $10{,}000$ training points from $N(0,1)$ clipped to $[-1,1]$, tests in $[-1,1]$, $[-1,0]$, and $[0,1]$, and $50$ runs for stability [2510.01663]. The metrics are test RMSE, ranking stability under shifts, symbolic recovery quality, convergence of Shapley estimation, and runtime overhead.

The paper reports that ShapKAN yields consistent neuron rankings across domains with small standard deviations, typically $<0.01$–$0.1$ after normalization, while vanilla KAN scores fluctuate heavily. For the special-function task $f_2$, the least important neuron’s vanilla score varies from approximately $13\%$ to approximately $27$–$32\%$ across ranges, whereas ShapKAN keeps the two top neurons stable and the rest below approximately $15\%$ [2510.01663].

Under equal parameter budgets and pruning counts, ShapKAN consistently reduces test RMSE relative to vanilla KAN:

| Function | Vanilla prune, RMSE | ShapKAN prune, RMSE |
|---|---|---|
| $f_1$ (Multiplication) | [0,3,4], $0.00055\pm0.00008$ | [2,3,4], $0.00031\pm0.00005$ |
| $f_2$ (Special) | [2,3,4], $0.558\pm0.030$ | [1,2,3], $0.536\pm0.013$ |
| $f_3$ (Phase) | [1,3,4], $0.129\pm0.041$ | [1,2,3], $0.109\pm0.013$ |
| $f_4$ (Complex) | [0,2,3,4], $0.619\pm0.015$ | [0,1,3,4], $0.612\pm0.012$ |

The symbolic consequences are similarly emphasized. On $f_1$ under covariate shift, ShapKAN recovers the ground truth $x_1x_2 + c$, whereas vanilla KAN produces the spurious expression $-0.01x_2 + 0.01e^{x_1} + c$. For $f_3$, ShapKAN selects $x^4$ edges and a $\tanh$ top layer consistent with the true form, while vanilla KAN selects a sinusoidal edge spuriously [2510.01663]. Exact Shapley computation takes approximately $0.6$–$0.7$s per small layer; approximation with $32$–$1024$ samples has comparable or slightly higher time but negligible overhead relative to training and inference, and antithetic sampling further reduces variance with similar runtime.

The same paper extends the comparison to Census-income, MNIST, and Airbnb, with KAN widths such as $[40,12,6,4,2]$, $[49,16,12,10,10]$, and $[15,10,8,6,4,1]$, parameter counts from $4.7$k to $17.6$k, and LBFGS training [2510.01663]. The baselines are vanilla KAN pruning, DropKAN, and an MLP with similar parameter counts. ShapKAN is reported to consistently outperform vanilla KAN and DropKAN across pruning ratios; MLP remains strong but lacks KAN’s symbolic recovery advantages, and DropKAN often degrades substantially, with Airbnb RMSE greater than $0.3$ for high pruning ratios.

## 5. Alternative uses of the term “ShapKAN”

The term is not semantically uniform across the KAN literature. At least three distinct meanings appear in the supplied papers:

| Usage | Core idea | Representative paper |
|---|---|---|
| Shapley-based ShapKAN | Node-level attribution and pruning via layer-local Shapley values | [2510.01663] |
| Shape-centric convolutional ShapKAN | Learnable univariate functions parameterize filter shape rather than per-edge value transforms | [2606.24371] |
| Shape-parameter-adaptive ShapKAN | RBF-KAN with LOOCV-initialized and trainable kernel shape parameter | [2605.21534] |

In the convolutional usage, the paper "Structural Kolmogorov-Arnold Convolutions" states that a ShapKAN is a KAN whose learnable univariate functions primarily parameterize or generate the filter’s spatial shape rather than act on the pixel values of each kernel entry [2606.24371]. RF-KAN is identified there as the canonical ShapKAN. The filter is synthesized from oriented ridge profiles expanded in a localized oscillatory Morlet basis with content-adaptive amplitudes, while pixel values enter linearly. Under a matched four-layer protocol at about $0.4$M parameters, RF-KAN and SV-KAN reach $88.47\pm0.10\%$ and $88.20\pm0.31\%$ on CIFAR-10 and $64.40\pm0.19\%$ and $64.57\pm0.30\%$ on CIFAR-100, both above a plain convolution and every per-edge KAN tested, including the official Gram variant, at roughly a fifth of the parameters [2606.24371].

In the RBF-based usage, the paper "Adaptive RBF-KAN" explicitly notes that “ShapKAN” refers to shape-parameter-adaptive KAN and is unrelated to SHAP values [2605.21534]. Here the emphasis is on replacing spline edge functions with RBF expansions and learning the radial kernel shape parameter jointly with network weights, initialized by leave-one-out cross-validation. The framework supports Gaussian, Matérn, and Wendland kernels. On benchmark functions over $[0,1]^2$, the paper reports that Gaussian kernels are best for smooth targets, low-smoothness Matérn kernels for discontinuities, compactly supported Wendland kernels for oscillations, and higher-smoothness Wendland kernels for localized peaks [2605.21534].

A common misconception is therefore terminological: “ShapKAN” does not denote a single standardized method across the literature. In one paper it abbreviates Shapley-based attribution for pruning [2510.01663]; in another it denotes shape-centric structural convolution [2606.24371]; in another it refers to adaptive radial kernel shape parameters and is stated to be unrelated to SHAP [2605.21534]. The shared element is not a single algorithm but the exploitation of structural degrees of freedom in KANs.

## 6. Practical implications, limitations, and open directions

For the Shapley-based pruning framework, the practical guidance is explicit. Layer-wise Shapley values are computed on held-out validation or training data via permutation sampling, preferably with antithetic pairs; exact Shapley is used for small layers with $n<8$, while $m\approx128$–$1024$ permutations are recommended for wider layers depending on desired stability [2510.01663]. Bottom-up pruning is preferred, the input layer is not pruned with this method, and recommended KAN hyperparameters include B-spline order $3$, grid size $3$–$5$, and LBFGS training. The paper suggests starting with number pruning by removing the $20$–$40\%$ lowest-Shapley neurons per layer, or ratio pruning with $\eta\approx0.05$–$0.15$, followed by optional short fine-tuning.

The limitations are also structural. Exact Shapley scales poorly with width; permutation sampling is unbiased and converges fast but remains stochastic; antithetic sampling improves small-sample variance [2510.01663]. Correlated neurons may complicate attribution, and the paper notes that higher-order Shapley interactions could help. The choice of value function matters: the prediction game is label-free and general, whereas a validation game may improve fidelity but requires labels. Input-layer feature pruning is explicitly avoided because it requires conditional input modeling. Proposed extensions include edge-level pruning, global versus local importance aggregation across layers, interaction indices such as shapiq, improved estimators based on control variates or stratified permutations, and integration with training via joint regularization guided by Shapley [2510.01663].

At the broader KAN level, a second misconception concerns what interpretability means in this model class. KANs are intrinsically interpretable because each edge function is a univariate curve that can be visualized, probed, sparsified, pruned, and in some cases snapped to a symbolic form [2404.19756]. ShapKAN in the Shapley sense does not create interpretability ex nihilo; it refines the simplification and attribution pipeline by replacing unstable magnitude heuristics with output-based cooperative-game scores. This suggests that ShapKAN is best understood as a method for preserving the interpretability advantages already latent in KANs while making pruning more robust to reparameterization and covariate shift [2510.01663].

Taken together, the literature uses “ShapKAN” to name three different attempts to regularize, simplify, or structurally bias KANs. The Shapley-based formulation is the most direct answer to pruning instability in spline KANs [2510.01663]. The convolutional shape-centric formulation shifts learnable functions from values to filter geometry [2606.24371]. The RBF-based formulation shifts attention from spline coefficients to adaptive kernel width and smoothness [2605.21534]. The plurality of meanings is itself informative: in KAN research, “shape” and “attribution” are both active loci of innovation because the architecture exposes functional structure at the edge level in a way that conventional MLP parameterizations do not [2404.19756].

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