Table of Contents
Fetching ...

Beyond TreeSHAP: Efficient Computation of Any-Order Shapley Interactions for Tree Ensembles

Maximilian Muschalik, Fabian Fumagalli, Barbara Hammer, Eyke Hüllermeier

TL;DR

This work presents TreeSHAP-IQ, an efficient method to compute any-order additive Shapley interactions for predictions of tree-based models, supported by a mathematical framework that exploits polynomial arithmetic to compute the interaction scores in a single recursive traversal of the tree, akin to Linear TreeSHAP.

Abstract

While shallow decision trees may be interpretable, larger ensemble models like gradient-boosted trees, which often set the state of the art in machine learning problems involving tabular data, still remain black box models. As a remedy, the Shapley value (SV) is a well-known concept in explainable artificial intelligence (XAI) research for quantifying additive feature attributions of predictions. The model-specific TreeSHAP methodology solves the exponential complexity for retrieving exact SVs from tree-based models. Expanding beyond individual feature attribution, Shapley interactions reveal the impact of intricate feature interactions of any order. In this work, we present TreeSHAP-IQ, an efficient method to compute any-order additive Shapley interactions for predictions of tree-based models. TreeSHAP-IQ is supported by a mathematical framework that exploits polynomial arithmetic to compute the interaction scores in a single recursive traversal of the tree, akin to Linear TreeSHAP. We apply TreeSHAP-IQ on state-of-the-art tree ensembles and explore interactions on well-established benchmark datasets.

Beyond TreeSHAP: Efficient Computation of Any-Order Shapley Interactions for Tree Ensembles

TL;DR

This work presents TreeSHAP-IQ, an efficient method to compute any-order additive Shapley interactions for predictions of tree-based models, supported by a mathematical framework that exploits polynomial arithmetic to compute the interaction scores in a single recursive traversal of the tree, akin to Linear TreeSHAP.

Abstract

While shallow decision trees may be interpretable, larger ensemble models like gradient-boosted trees, which often set the state of the art in machine learning problems involving tabular data, still remain black box models. As a remedy, the Shapley value (SV) is a well-known concept in explainable artificial intelligence (XAI) research for quantifying additive feature attributions of predictions. The model-specific TreeSHAP methodology solves the exponential complexity for retrieving exact SVs from tree-based models. Expanding beyond individual feature attribution, Shapley interactions reveal the impact of intricate feature interactions of any order. In this work, we present TreeSHAP-IQ, an efficient method to compute any-order additive Shapley interactions for predictions of tree-based models. TreeSHAP-IQ is supported by a mathematical framework that exploits polynomial arithmetic to compute the interaction scores in a single recursive traversal of the tree, akin to Linear TreeSHAP. We apply TreeSHAP-IQ on state-of-the-art tree ensembles and explore interactions on well-established benchmark datasets.
Paper Structure (47 sections, 7 theorems, 45 equations, 19 figures, 2 tables, 3 algorithms)

This paper contains 47 sections, 7 theorems, 45 equations, 19 figures, 2 tables, 3 algorithms.

Key Result

Proposition 1

For $\psi$ and $p,q \in \mathbb{R}[x]_d$,

Figures (19)

  • Figure 1: Network Plot after Inglis.2022 for a test instance of the German Credit dataset for visualizing local feature attribution and interaction.
  • Figure 2: Force plots of positive (red) and negative (blue) SVs and n-SII scores for an instance of the California dataset The longit. feature has a high contribution, describing the proximity to the ocean, which affects the price. TreeSHAP ($s_0=1$) reveals this contribution. It also shows that latit. contributed positively. TreeSHAP-IQ, e.g. $s_0\geq2$, reveals that this contribution can be (mostly) attributed to the interaction latit. x longit., which reveals that the exact location, and not latit., is meaningful.
  • Figure 3: Notations in TreeSHAP-IQ and Linear TreeSHAP.
  • Figure 4: Waterfall chart for n-SII scores with $s_0=3$ and a prediction of the Bike regression dataset.
  • Figure 5: Visualization of positive and negative n-SII scores per feature with $s_0=7$ for an observation in German Credit.
  • ...and 14 more figures

Theorems & Definitions (16)

  • Definition 1: SII, Grabisch.1999 Grabisch.1999
  • Definition 2: Summary Polynomial (SP), Yu.2022 Yu.2022
  • Proposition 1: Yu.2022 Yu.2022
  • Theorem 1: Yu.2022 Yu.2022
  • Proposition 2
  • Definition 3: Interaction Polynomial (IP)
  • Definition 4: Coefficient sum $\kappa$
  • Proposition 3
  • Definition 5: Quotient Polynomial (QP)
  • Proposition 4
  • ...and 6 more