Abstract
Thermostat is a massive open-source "data hub" and software library containing over 200,000 pre-computed NLP model explanations. By providing easy access to feature attribution maps that originally took over 10,000 GPU hours to generate, the authors aim to democratize explainability research and eliminate the massive computational and technical barriers currently facing the field.
Introduction: The Black Box Problem in NLP
Deep neural networks are notoriously "black boxes." To understand why a model makes a specific prediction, researchers use feature attribution methods (or "explainers") to assign importance scores to input tokens—essentially creating a heatmap of what the model was "looking at." However, generating these explanations at scale is hindered by three primary challenges: high computational costs, implementation complexity requiring expert knowledge, and a lack of centralization that prevents replication and comparison across studies.
The Thermostat Hub
The authors developed THERMOSTAT as a standardized repository organized around three coordinates: Dataset, Model, and Explainer. Utilizing the Captum library, they focused on five prominent feature attribution methods: Layer Gradient x Activation (LGxA), Integrated Gradients (LIG), Local Interpretable Model-agnostic Explanations (LIME), Occlusion (Occ), and Shapley Value Sampling (SVS).
Built on top of the Hugging Face datasets library, THERMOSTAT allows users to load explanations with minimal code. The library also includes a visualization tool to render these attributions as token-level heatmaps directly in a browser or notebook environment.
Datasets and Models
THERMOSTAT currently covers four major NLP benchmarks, focusing on their respective test or validation splits:
- IMDb: Sentiment analysis (25,000 instances).
- MultiNLI: Natural language inference (9,815 instances).
- XNLI: Cross-lingual natural language inference (5,010 instances).
- AG News: Topic classification (7,600 instances).
These datasets were paired with five state-of-the-art transformer architectures: ALBERT, BERT, ELECTRA, RoBERTa, and XLNet.
Key Insights and Analysis
"Green" and Democratized NLP
By centralizing explanations, THERMOSTAT prevents the community from redundantly burning thousands of GPU hours to re-calculate the same attribution maps. It makes "expensive" explanations accessible to anyone with an internet connection, regardless of their access to high-performance computing clusters.
Model Disagreement and Explainer Comparison
THERMOSTAT facilitates the analysis of cases where models disagree. By examining heatmaps, researchers can determine if a model was distracted by a "signal phrase" or if it correctly understood the context. Furthermore, the authors found that different explainers often disagree on token importance, highlighting the need for a central hub to benchmark these methods systematically.
Results and Impact
The collection includes over 200,000 explanations, representing an investment of over 10,000 GPU hours (equivalent to over a year of continuous compute on a single high-end card). At the time of publication, 86 out of 90 planned configurations were available. The library's utility was demonstrated by replicating complex findings from previous studies with just a few lines of code.
Limitations and Future Work
Currently, THERMOSTAT focuses exclusively on text classification. Future work aims to expand to more diverse NLP tasks like machine translation and summarization, and to integrate with other analysis platforms like the Language Interpretability Tool (LIT).
Summary updated