Explainable time-series forecasting with sampling-free SHAP for Transformers

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Hertel, Matthias, Pütz, Sebastian, Mikut, Ralf, Hagenmeyer, Veit, Schäfer, Benjamin
Format: Preprint
Published: 2025
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866911335438090240
author Hertel, Matthias
Pütz, Sebastian
Mikut, Ralf
Hagenmeyer, Veit
Schäfer, Benjamin
author_facet Hertel, Matthias
Pütz, Sebastian
Mikut, Ralf
Hagenmeyer, Veit
Schäfer, Benjamin
contents Time-series forecasts are essential for planning and decision-making in many domains. Explainability is key to building user trust and meeting transparency requirements. Shapley Additive Explanations (SHAP) is a popular explainable AI framework, but it lacks efficient implementations for time series and often assumes feature independence when sampling counterfactuals. We introduce SHAPformer, an accurate, fast and sampling-free explainable time-series forecasting model based on the Transformer architecture. It leverages attention manipulation to make predictions based on feature subsets. SHAPformer generates explanations in under one second, several orders of magnitude faster than the SHAP Permutation Explainer. On synthetic data with ground truth explanations, SHAPformer provides explanations that are true to the data. Applied to real-world electrical load data, it achieves competitive predictive performance and delivers meaningful local and global insights, such as identifying the past load as the key predictor and revealing a distinct model behavior during the Christmas period.
format Preprint
id arxiv_https___arxiv_org_abs_2512_20514
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Explainable time-series forecasting with sampling-free SHAP for Transformers
Hertel, Matthias
Pütz, Sebastian
Mikut, Ralf
Hagenmeyer, Veit
Schäfer, Benjamin
Machine Learning
Time-series forecasts are essential for planning and decision-making in many domains. Explainability is key to building user trust and meeting transparency requirements. Shapley Additive Explanations (SHAP) is a popular explainable AI framework, but it lacks efficient implementations for time series and often assumes feature independence when sampling counterfactuals. We introduce SHAPformer, an accurate, fast and sampling-free explainable time-series forecasting model based on the Transformer architecture. It leverages attention manipulation to make predictions based on feature subsets. SHAPformer generates explanations in under one second, several orders of magnitude faster than the SHAP Permutation Explainer. On synthetic data with ground truth explanations, SHAPformer provides explanations that are true to the data. Applied to real-world electrical load data, it achieves competitive predictive performance and delivers meaningful local and global insights, such as identifying the past load as the key predictor and revealing a distinct model behavior during the Christmas period.
title Explainable time-series forecasting with sampling-free SHAP for Transformers
topic Machine Learning
url https://arxiv.org/abs/2512.20514