Introduction: The Lexical Overlap Problem
Pretrained language models like BERT have revolutionized NLP, yet they exhibit a surprising weakness: they struggle to represent the semantics of short phrases. Instead of capturing deep compositional meaning, standard BERT often relies on lexical overlap—simple string matching—to determine similarity.
As shown in the comparison above, when querying for phrases similar to "pulls the trigger," standard BERT models return variations of the same words (e.g., "pulled the trigger"). In contrast, Phrase-BERT identifies semantically related but lexically distinct phrases like "picks up his gun" or "takes aim." This reliance on surface-level features limits BERT's utility in tasks requiring nuanced phrase understanding, such as semantic parsing or topic modeling.
Methodology: Contrastive Learning for Phrases
To overcome this limitation, the authors introduce Phrase-BERT, a model fine-tuned using a contrastive learning objective. The training process utilizes two novel, automatically generated datasets designed to break the model's dependence on lexical overlap.
1. Lexically Diverse Paraphrases
The model is trained on 100,000 anchor phrases paired with paraphrases generated by a GPT-2 model. Crucially, these paraphrases are constrained to have zero non-stopword overlap with the original phrase (e.g., "complete control" becomes "full power of the system"). This forces the model to learn semantic equivalence rather than word matching.
2. Phrases in Context
To capture how phrases function in natural language, the authors extract phrases and their 120-token surrounding contexts from the Books3 corpus. The model learns to align the embedding of a phrase with the embedding of its context (with the phrase itself masked), further enriching the semantic representation.
Evaluation and Key Results
Phrase-BERT was evaluated across several semantic relatedness benchmarks, including Turney, BiRD, and PPDB.
- Semantic Relatedness: Phrase-BERT consistently outperforms GloVe, BERT, and Sentence-BERT. On the PPDB-filtered dataset—specifically designed to remove lexical overlap cues—Phrase-BERT achieved an accuracy of 68.0, significantly higher than standard BERT (60.1) and Sentence-BERT (64.2).
- Lexical Diversity: Analysis of the vector space confirms that Phrase-BERT's nearest neighbors are more lexically diverse. The Longest Common Substring (LCS) precision for Phrase-BERT is lower than Sentence-BERT (47.6 vs. 51.1), indicating it is less prone to "cheating" via string matching.
Application: Neural Topic Modeling
A major contribution of this work is the Phrase-based Neural Topic Model (PNTM). Traditional topic models like LDA produce lists of unigrams, which can be difficult to interpret. By utilizing Phrase-BERT embeddings within an autoencoder-based framework, PNTM generates topics described by a mix of words and coherent phrases.
Human evaluations (word intrusion precision) show that PNTM (79.1) vastly outperforms traditional phrase-LDA (51.6) and unigram-based neural models (69.6). PNTM remains robust and interpretable even when the number of topics is scaled up to 1,000, a regime where word-level models typically degrade.
Conclusion
Phrase-BERT successfully addresses the "lexical overlap crutch" in pretrained language models. By training on diverse paraphrases and contextual information, it creates a more semantically robust embedding space for phrases. This advancement not only improves performance on standard benchmarks but also enables more sophisticated and human-readable corpus exploration through phrase-based topic modeling.
Summary updated