SHAP values for Explaining CNN-based Text Classification Models

Wei Zhao, Tarun Joshi, Vijayan N. Nair, Agus Sudjianto

Abstract

Deep neural networks are increasingly used in natural language processing (NLP) models. However, the need to interpret and explain the results from complex algorithms are limiting their widespread adoption in regulated industries such as banking. There has been recent work on interpretability of machine learning algorithms with structured data. But there are only limited techniques for NLP applications where the problem is more challenging due to the size of the vocabulary, high-dimensional nature, and the need to consider textual coherence and language structure. This paper develops a methodology to compute SHAP values for local explainability of CNN-based text classification models. The approach is also extended to compute global scores to assess the importance of features. The results are illustrated on sentiment analysis of Amazon Electronic Review data.

Empirical ResultsBrowse all benchmarks →

BenchmarkMethodMetricScoreProtocol / Evidence
Amazon Electronics · Amazon Elec ReviewsCNN SHAP (URA)Global CNN SHAP score0.836Sentiment Analysis
Source quote
L434: 0.836 poor
Amazon Electronics · Amazon Elec ReviewsCNN SHAP (URA)Global CNN SHAP score0.757Sentiment Analysis
Source quote
L435: 0.757 very pleased with
Amazon Electronics · Amazon Elec ReviewsCNN SHAP (URA)Global CNN SHAP score0.727Sentiment Analysis
Source quote
L438: 0.727 terrible
Amazon Electronics · Amazon Elec ReviewsCNN SHAP (URA)Global CNN SHAP score0.689Sentiment Analysis
Source quote
L447: 0.689 beat
Amazon Electronics · Amazon Elec ReviewsCNN SHAP (URA)Global CNN SHAP score0.663Sentiment Analysis
Source quote
L442: 0.663 same problem
Amazon Electronics · Amazon Elec ReviewsCNN SHAP (URA)Global CNN SHAP score0.733Sentiment Analysis
Source quote
L439: 0.733 very happy with
BibTeX
@misc{zhao2020shap,
  author = {Wei Zhao and Tarun Joshi and Vijayan N. Nair and Agus Sudjianto},
  title = {{SHAP values for Explaining CNN-based Text Classification Models}},
  year = {2020},
  eprint = {2008.11825},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2008.11825},
}

Loading related content...

Figure