Table of Contents
Fetching ...

Application of integrated gradients explainability to sociopsychological semantic markers

Ali Aghababaei, Jan Nikadon, Magdalena Formanowicz, Maria Laura Bettinsoli, Carmen Cervone, Caterina Suitner, Tomaso Erseghe

TL;DR

The paper addresses explainability for sociopsychological textual markers beyond sentiment by applying word-level Integrated Gradients (IG) to transformer-based agency classifiers. It systematically benchmarks IG against Sequential IG, DeepLIFT, and GradientSHAP, analyzes baseline and step-size effects, and validates with a RoBERTa-based agency predictor (BERTAgent). A rendering pipeline aligned with SpaCy and negation handling translates attributions into readable word-level cues, and a small-dataset, overfitting strategy reveals salient keywords to characterize classes, supporting dictionary expansion. Across multiple datasets, IG reliably highlights agentic terms and demonstrates practical utility for sociopsychology and communication strategy in both data-rich and data-scarce settings, with mathematical grounding in attribution as $F(x)-F(x_0)$ computed via $N$ steps along a path from baseline $x_0$ to input $x$.

Abstract

Classification of textual data in terms of sentiment, or more nuanced sociopsychological markers (e.g., agency), is now a popular approach commonly applied at the sentence level. In this paper, we exploit the integrated gradient (IG) method to capture the classification output at the word level, revealing which words actually contribute to the classification process. This approach improves explainability and provides in-depth insights into the text. We focus on sociopsychological markers beyond sentiment and investigate how to effectively train IG in agency, one of the very few markers for which a verified deep learning classifier, BERTAgent, is currently available. Performance and system parameters are carefully tested, alternatives to the IG approach are evaluated, and the usefulness of the result is verified in a relevant application scenario. The method is also applied in a scenario where only a small labeled dataset is available, with the aim of exploiting IG to identify the salient words that contribute to building the different classes that relate to relevant sociopsychological markers. To achieve this, an uncommon training procedure that encourages overfitting is employed to enhance the distinctiveness of each class. The results are analyzed through the lens of social psychology, offering valuable insights.

Application of integrated gradients explainability to sociopsychological semantic markers

TL;DR

The paper addresses explainability for sociopsychological textual markers beyond sentiment by applying word-level Integrated Gradients (IG) to transformer-based agency classifiers. It systematically benchmarks IG against Sequential IG, DeepLIFT, and GradientSHAP, analyzes baseline and step-size effects, and validates with a RoBERTa-based agency predictor (BERTAgent). A rendering pipeline aligned with SpaCy and negation handling translates attributions into readable word-level cues, and a small-dataset, overfitting strategy reveals salient keywords to characterize classes, supporting dictionary expansion. Across multiple datasets, IG reliably highlights agentic terms and demonstrates practical utility for sociopsychology and communication strategy in both data-rich and data-scarce settings, with mathematical grounding in attribution as computed via steps along a path from baseline to input .

Abstract

Classification of textual data in terms of sentiment, or more nuanced sociopsychological markers (e.g., agency), is now a popular approach commonly applied at the sentence level. In this paper, we exploit the integrated gradient (IG) method to capture the classification output at the word level, revealing which words actually contribute to the classification process. This approach improves explainability and provides in-depth insights into the text. We focus on sociopsychological markers beyond sentiment and investigate how to effectively train IG in agency, one of the very few markers for which a verified deep learning classifier, BERTAgent, is currently available. Performance and system parameters are carefully tested, alternatives to the IG approach are evaluated, and the usefulness of the result is verified in a relevant application scenario. The method is also applied in a scenario where only a small labeled dataset is available, with the aim of exploiting IG to identify the salient words that contribute to building the different classes that relate to relevant sociopsychological markers. To achieve this, an uncommon training procedure that encourages overfitting is employed to enhance the distinctiveness of each class. The results are analyzed through the lens of social psychology, offering valuable insights.

Paper Structure

This paper contains 15 sections, 1 equation, 8 figures, 1 table.

Figures (8)

  • Figure 1: Number of tweets/sentences as a function of their length, in the four datasets.
  • Figure 2: Comprehensiveness and sufficiency in IG (with $N=300$ steps) as a function of the fraction $f$ in the four datasets, and for different baseline choices.
  • Figure 3: Baseline output $F(\hbox{\boldmath{$x$}}_0)$ (above) and normalized baseline output (below) in IG (with $N=300$ steps) as a function of the number $k$ of tokens in a text, and for different baseline choices.
  • Figure 4: Comprehensiveness and sufficiency in IG (with $N=300$ steps) as a function of the fraction $f$ in the Snippets dataset with zero baseline, and for different number of steps $N$.
  • Figure 5: Approximation error statistics in IG (with $N=300$ steps) as a function of the number of steps $N$ in the four datasets, and for different baseline choices.
  • ...and 3 more figures