Contrast-CAT: Contrasting Activations for Enhanced Interpretability in Transformer-based Text Classifiers
On the map: Mechanistic interpretability → Circuits and mechanistic analysis
Abstract (arXiv)
Transformers have profoundly influenced AI research, but explaining their decisions remains challenging -- even for relatively simpler tasks such as classification -- which hinders trust and safe deployment in real-world applications. Although activation-based attribution methods effectively explain transformer-based text classification models, our findings reveal that these methods can be undermined by class-irrelevant features within activations, leading to less reliable interpretations. To address this limitation, we propose Contrast-CAT, a novel activation contrast-based attribution method that refines token-level attributions by filtering out class-irrelevant features. By contrasting the activations of an input sequence with reference activations, Contrast-CAT generates clearer and more faithful attribution maps. Experimental results across various datasets and models confirm that Contrast-CAT consistently outperforms state-of-the-art methods. Notably, under the MoRF setting, it achieves average improvements of x1.30 in AOPC and x2.25 in LOdds over the most competing methods, demonstrating its effectiveness in enhancing interpretability for transformer-based text classification.
Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). Placed in Circuits and mechanistic analysis, one of 13 directions in Mechanistic interpretability. Builds on 26 of its 45 references that are in the map. First posted on arXiv 27 Jul 2025.
Builds on
26 of 45 references.
References · 26
- 2017Attention Is All You Needcited by 60,361
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,399
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,372
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
- 2016Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localizationcited by 6,733
- 2019DistilBERT, a distilled version of BERT: smaller, faster, cheaper and lightercited by 4,307
- 2015Character-level Convolutional Networks for Text Classificationcited by 2,330
- 2017Learning Important Features Through Propagating Activation Differencescited by 1,458
- 2019What Does BERT Look At? An Analysis of BERT's Attentioncited by 1,003
- 2019Attention is not Explanationcited by 929
- 2019Analyzing Multi-Head Self-Attention: Specialized Heads Do the Heavy Lifting, the Rest Can Be Prunedcited by 856
- 2018RISE: Randomized Input Sampling for Explanation of Black-box Modelscited by 838
14 more
- 2020Quantifying Attention Flow in Transformerscited by 775
- 2019Attention is not not Explanationcited by 636
- 2020Transformer Interpretability Beyond Attention Visualizationcited by 627
- 2019Score-CAM: Score-Weighted Visual Explanations for Convolutional Neural Networkscited by 582
- 2016From Softmax to Sparsemax: A Sparse Model of Attention and Multi-Label Classificationcited by 341
- 2022A Consistent and Efficient Evaluation Strategy for Attribution Methodscited by 102
- 2020Generating Hierarchical Explanations on Text Classification via Feature Interaction Detectioncited by 57
- 2022GlobEnc: Quantifying Global Token Attribution by Incorporating the Whole Encoder Layer in Transformerscited by 44
- 2023Quantifying Context Mixing in Transformerscited by 43
- 2022Grad-SAM: Explaining Transformers via Gradient Self-Attention Mapscited by 42
- 2018Understanding Individual Decisions of CNNs via Contrastive Backpropagationcited by 40
- 2021Enjoy the Salience: Towards Better Transformer-based Faithful Explanations with Word Saliencecited by 16
- 2020Telling BERT's full story: from Local Attention to Global Aggregationcited by 15
- 2020Deriving Contextualised Semantic Features from BERT (and Other Transformer Model) Embeddingscited by 12
Built on by
Citing papers per year: 2026: 1.
1 paper.
Similar, not cited
Close in wording, no citation either way
- 2026READER: Reasoning-Enhanced AI-Generated Text Detection
- 2021Supervised Graph Contrastive Pretraining for Text Classification
- 2025DEXTER: Diffusion-Guided EXplanations with TExtual Reasoning for Vision Models
- 2026Contrastive Attribution in the Wild: An Interpretability Analysis of LLM Failures on Realistic Benchmarks
- 2026Detecting the Machine: A Comprehensive Benchmark of AI-Generated Text Detectors Across Architectures, Domains, and Adversarial Conditions
- 2025DePass: Unified Feature Attributing by Simple Decomposed Forward Pass
- 2026Evaluating Explainable AI Attribution Methods in Neural Machine Translation via Attention-Guided Knowledge Distillation
- 2025Feature-Level Insights into Artificial Text Detection with Sparse Autoencoders