Structured Self-Attention Weights Encode Semantics in Sentiment Analysis
Not on the map. Why?
Abstract (arXiv)
Neural attention, especially the self-attention made popular by the Transformer, has become the workhorse of state-of-the-art natural language processing (NLP) models. Very recent work suggests that the self-attention in the Transformer encodes syntactic information; Here, we show that self-attention scores encode semantics by considering sentiment analysis tasks. In contrast to gradient-based feature attribution methods, we propose a simple and effective Layer-wise Attention Tracing (LAT) method to analyze structured attention weights. We apply our method to Transformer models trained on two tasks that have surface dissimilarities, but share common semantics---sentiment analysis of movie reviews and time-series valence prediction in life story narratives. Across both tasks, words with high aggregated attention weights were rich in emotional semantics, as quantitatively validated by an emotion lexicon labeled by human annotators. Our results show that structured attention weights encode rich semantics in sentiment analysis, and match human interpretations of semantics.
Key facts. Cited by 9 papers in the map (data through 7 Oct 2026). First posted on arXiv 10 Oct 2020.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2021: 2; 2022: 1; 2023: 1; 2024: 0; 2025: 3; 2026: 2.
9 papers.
- 2023Explainability for Large Language Models: A Surveycited by 331
- 2021On Explaining Your Explanations of BERT: An Empirical Study with Sequence Classificationcited by 21
- 2025LinguaLens: Towards Interpreting Linguistic Mechanisms of Large Language Models via Sparse Auto-Encodercited by 13
- 2025FinTRec: Transformer Based Unified Contextual Ads Targeting and Personalization for Financial Applicationscited by 4
- 2021Does BERT look at sentiment lexicon?cited by 1
- 2022Cross-lingual AMR Aligner: Paying Attention to Cross-Attentioncited by 0
- 2025PLEX: Perturbation-free Local Explanations for LLM-Based Text Classificationcited by 0
- 2026TimeSliver : Symbolic-Linear Decomposition for Explainable Time Series Classificationcited by 0
- 2026A Systematic Benchmark of Explainable Methods for Temporal Attribution in Sequential Recommendation Systemscited by 0
- 2026A Systematic Benchmark of Explainable Methods for Temporal Attribution in Sequential Recommendation Systems23 Sep 2026
- 2026TimeSliver : Symbolic-Linear Decomposition for Explainable Time Series Classification29 Jan 2026
- 2025FinTRec: Transformer Based Unified Contextual Ads Targeting and Personalization for Financial Applications18 Nov 2025
- 2025PLEX: Perturbation-free Local Explanations for LLM-Based Text Classification12 Jul 2025
- 2025LinguaLens: Towards Interpreting Linguistic Mechanisms of Large Language Models via Sparse Auto-Encoder27 Feb 2025
- 2023Explainability for Large Language Models: A Survey2 Sep 2023
- 2022Cross-lingual AMR Aligner: Paying Attention to Cross-Attention15 Jun 2022
- 2021Does BERT look at sentiment lexicon?19 Nov 2021
- 2021On Explaining Your Explanations of BERT: An Empirical Study with Sequence Classification1 Jan 2021