Provably Accurate Shapley Value Estimation via Leverage Score Sampling
Christopher Musco, R. Teal Witter
TL;DR
This paper addresses the computational bottleneck of Shapley value estimation for feature attribution in complex models, where exact computation costs grow as $O(2^n)$. It introduces Leverage SHAP, a near-linear-sample method that leverages leverage-score sampling to solve the associated regression problem with $O(n \log n)$ evaluations in expectation and strong non-asymptotic guarantees: with probability $1-\delta$, $\| \mathbf{Z}\tilde{\boldsymbol{\phi}} - \mathbf{y} \|_2^2 \le (1+\epsilon)\| \mathbf{Z}\boldsymbol{\phi}-\mathbf{y} \|_2^2$. A key theoretical contribution is the closed-form leverage scores $\ell_{S}=\binom{n}{|S|}^{-1}$, enabling efficient, unbiased sampling of subsets by size. The algorithm integrates paired sampling and sampling without replacement, achieving accurate estimates with $m=O(n \log(n/\delta)+ n/(\epsilon\delta))$ value-function evaluations and $O(mn^2)$ regression time. Empirically, Leverage SHAP consistently outperforms the optimized Kernel SHAP implementation across eight datasets, particularly when $n$ is large or the set-function $v$ is noisy, highlighting its practical impact for explainable AI and robust feature attribution.
Abstract
Originally introduced in game theory, Shapley values have emerged as a central tool in explainable machine learning, where they are used to attribute model predictions to specific input features. However, computing Shapley values exactly is expensive: for a general model with $n$ features, $O(2^n)$ model evaluations are necessary. To address this issue, approximation algorithms are widely used. One of the most popular is the Kernel SHAP algorithm, which is model agnostic and remarkably effective in practice. However, to the best of our knowledge, Kernel SHAP has no strong non-asymptotic complexity guarantees. We address this issue by introducing Leverage SHAP, a light-weight modification of Kernel SHAP that provides provably accurate Shapley value estimates with just $O(n\log n)$ model evaluations. Our approach takes advantage of a connection between Shapley value estimation and agnostic active learning by employing leverage score sampling, a powerful regression tool. Beyond theoretical guarantees, we show that Leverage SHAP consistently outperforms even the highly optimized implementation of Kernel SHAP available in the ubiquitous SHAP library [Lundberg & Lee, 2017].
