#3030th of 433 in ML frameworks and libraries

shap

Python library that explains ML model predictions with Shapley values

Run it:Vast.ai ↗ (opens in a new tab)Clore.ai ↗ (opens in a new tab)Affiliate links, no effect on a rank.

Stars
25.9k
License
MIT
Last commit
Nov 2026
Last release
Oct 2026
Language
Jupyter Notebook
Stars, last 35 weeks+886
25 Mar 2026: 25,014 stars1 Apr 2026: 25,052 stars8 Apr 2026: 25,105 stars15 Apr 2026: 25,142 stars22 Apr 2026: 25,184 stars29 Apr 2026: 25,216 stars6 May 2026: 25,249 stars13 May 2026: 25,277 stars20 May 2026: 25,322 stars27 May 2026: 25,346 stars3 Jun 2026: 25,377 stars10 Jun 2026: 25,404 stars17 Jun 2026: 25,431 stars24 Jun 2026: 25,453 stars1 Jul 2026: 25,481 stars8 Jul 2026: 25,507 stars15 Jul 2026: 25,533 stars22 Jul 2026: 25,555 stars29 Jul 2026: 25,584 stars5 Aug 2026: 25,599 stars12 Aug 2026: 25,615 stars19 Aug 2026: 25,632 stars26 Aug 2026: 25,645 stars2 Sept 2026: 25,664 stars9 Sept 2026: 25,680 stars16 Sept 2026: 25,710 stars23 Sept 2026: 25,734 stars30 Sept 2026: 25,750 stars7 Oct 2026: 25,771 stars14 Oct 2026: 25,791 stars21 Oct 2026: 25,805 stars28 Oct 2026: 25,822 stars4 Nov 2026: 25,837 stars11 Nov 2026: 25,848 stars18 Nov 2026: 25,869 stars25 Nov 2026: 25,900 stars

25,014 on 25 Mar 202625,900 on 25 Nov 2026

From GitHub's daily star counts.

Checked on GitHub.

Overview

SHAP computes per-feature attributions for model predictions using Shapley values. It has model-specific explainers (Tree, Deep, Gradient, Linear) and a model-agnostic Kernel explainer, plus plots such as waterfall, force, beeswarm, scatter and text. Tree SHAP has C++ implementations for XGBoost, LightGBM, CatBoost, scikit-learn and pyspark; transformers pipelines are supported for NLP.

Who it is for: Data scientists and ML engineers who need to interpret model predictions

Strengths

  • Exact, fast Tree SHAP in C++ for XGBoost, LightGBM, CatBoost, scikit-learn, pyspark
  • KernelExplainer works on any model that exposes a prediction function
  • Built-in plots: waterfall, force, beeswarm, scatter, bar, text, image
  • Optional GPU Tree SHAP via the separate shap-cuda package

Weaknesses

  • KernelExplainer is slower than the model-specific explainers
  • DeepExplainer supports TensorFlow/Keras; PyTorch support is described as preliminary
  • Some README examples use older Keras APIs such as K.get_session
  • Explains models but does not train, serve or monitor them

What it needs

  • GPU optional
  • Needs XGBoost, LightGBM, CatBoost, scikit-learn, TensorFlow/Keras, PyTorch, transformers
  • Models: XGBoost, LightGBM, CatBoost, scikit-learn, pyspark

What changed

  1. “Match KernelExplainer DataFrame columns to the background by name. Duplicated column names now raise an error, but worked previously. By @Atishyy27 in https://github.com/shap/shap/pull/5164.”

From the release notes. No flag means the note does not say so, not that the upgrade is safe. Releases and problems by RSS

Also in ML frameworks and libraries

See all 433
Also in ML frameworks and libraries
RankProjectScore
#28tabpfnPretrained transformer for tabular classification and regression, no per-dataset training Live demo ↗ (opens in a new tab)8.6k stars+239 (+2.9%) in 30 daysApache-2.084 out of 100
#29xgboostGradient boosted decision tree library for tabular machine learning29k starsApache-2.083 out of 100
#31sentence-transformersPython library for text embeddings, rerankers, and sparse and ColBERT-style models19.3k starsApache-2.083 out of 100
#32pysyftPython library for running data-owner-approved jobs on private data10.1k starsApache-2.083 out of 100
#33accelerateThin PyTorch wrapper that runs your training loop on CPU, GPU, TPU or multi-node10k starsApache-2.083 out of 100