Abstract
VAST (Valence-Assessing Semantics Test) is a novel intrinsic evaluation task designed for contextualized word embeddings (CWEs). By leveraging "valence"—the human association of words with pleasantness—VAST measures the correspondence between language model (LM) semantics and human judgments. Applying VAST to GPT-2 and seven other models across seven languages reveals critical insights into how models encode meaning. We find that word-level semantics are often masked in top layers by high-magnitude neurons dedicated to syntax, but these meanings can be recovered through principal component nullification. Our results demonstrate that VAST identifies a "middle-layer" peak for semantic representation and provides a more accurate lens for measuring social bias and word similarity, achieving a state-of-the-art score of 0.50 on SimLex-999 for GPT-2.
Introduction
While large language models (LLMs) like GPT-2 and BERT have revolutionized natural language processing, evaluating the "intrinsic" quality of the word meanings they generate remains a challenge. Unlike static embeddings, contextualized word embeddings (CWEs) change based on surrounding text. Existing evaluation frameworks often fail to account for the nuances of contextualization, subword tokenization, and the internal geometry of the model.
VAST addresses these gaps by using valence as a universal semantic signal. Because humans generally agree on the pleasantness of words (e.g., "joy" vs. "death"), valence provides a stable benchmark to test how well a model's internal vectors align with human psychology.
Methodology
The VAST Algorithm
VAST employs the Single-Category Word Embedding Association Test (SC-WEAT) to determine how closely a specific word vector associates with "pleasant" versus "unpleasant" attribute words. The core metric is the Pearson’s correlation ($\rho$) between these model-derived associations and human-rated valence scores from established lexica, such as the Warriner (13,915 words), ANEW, and Bellezza datasets.
Contextual Settings
To isolate the effects of context, VAST evaluates words across four distinct environments:
- Random: The target word embedded in a random sentence from a Reddit corpus.
- Bleached: A neutral template (e.g., "This is [WORD]").
- Aligned: Context that matches the word's inherent valence.
- Misaligned: Context that clashes with the word's valence (e.g., a positive word in a negative sentence).
Principal Component (PC) Nullification
To investigate the geometry of the embedding space, the researchers used Principal Component Analysis (PCA) to identify dominant directions in the vector space. By mathematically nullifying high-magnitude components that do not contribute to semantic clarity, they attempted to recover "masked" word-level information.
Key Insights
The Middle-Layer Sweet Spot and Subword Assembly
In GPT-2, word-level semantics are not uniformly distributed. The study found that semantics are most stable and accurate around Layer 8. For common, singly-tokenized words, semantic representation is strong from the input layer (Layer 0). However, rare words broken into multiple subword tokens do not "assemble" into a coherent semantic representation until Layer 8, where they reach a Pearson's $\rho$ of 0.46.
The Syntax Mask in Top Layers
In the final layers of GPT-2 (e.g., Layer 12), the correlation with human valence typically drops significantly (to approximately $\rho = 0.32$). The authors discovered that this is not due to a loss of meaning, but rather a "masking" effect. A small number of high-magnitude neurons (as few as 8 out of 768) dominate the vector, encoding sentence-level syntax and next-word prediction features. By nullifying these non-semantic principal components, the valence correlation in the top layer jumped from 0.32 to 0.76.
Unmasking Social Bias
The "noise" in the top layers also obscures social biases. After isolating semantics through PC nullification, 8 out of 10 WEAT bias tests exhibited more stereotype-congruent biases. This suggests that non-semantic structures in LMs may hide the true extent of stereotypical associations within the model's weights.
Results and Validation
VAST's utility was validated against several classic word similarity benchmarks. By using VAST to identify optimal layers and applying de-noising techniques, the researchers achieved a score of 0.50 on SimLex-999 for GPT-2, surpassing the previous best of 0.45. Furthermore, the test proved robust across seven different languages using the MT5 model, confirming that valence is an effective cross-linguistic semantic probe.
Conclusion
VAST provides a powerful diagnostic tool for peering into the "semantic heart" of language models. It reveals that while top layers are optimized for task performance (like next-word prediction), the underlying word-level semantics remain present but obscured by syntactic geometry. Future work may leverage VAST to improve the training of rare subword tokens or to further investigate how specific syntactic features like tense and case interact with semantic encoding.
Summary updated