Introduction
Modern Natural Language Processing (NLP) is largely predicated on the principle of compositionality—the idea that the meaning of a complex expression is determined by the meanings of its constituent parts. While this approach is highly effective for literal language, it fails significantly when encountering idiomatic expressions (IEs). For instance, a standard model might interpret "kick the bucket" as semantically similar to "hit the pail," missing the figurative meaning of "to die."
This paper addresses the "idiomaticity gap" caused by data scarcity, representation bias toward literal meanings, and the resulting downstream failures in tasks like translation and sentiment analysis. The authors propose a specialized fine-tuning approach using an adaptive contrastive triplet loss and a custom semantic miner to bridge this gap.
Methodology: Adaptive Contrastive Triplet Loss
The core of the proposed method is a fine-tuning strategy based on Contrastive Learning. Unlike standard training that looks at individual sentences, this approach utilizes a triplet structure to force the model to learn nuanced semantic differences.
The Triplet Structure
The model processes three distinct inputs simultaneously:
- Anchor ($a$): A sentence containing an idiomatic expression (e.g., "He kicked the bucket").
- Positive ($p$): A correct paraphrase (e.g., "He passed away").
- Negative ($n$): An incorrect paraphrase, typically a literal interpretation of the idiom's words (e.g., "He struck the pail").
The loss function is designed to minimize the distance between the Anchor and the Positive while maximizing the distance between the Anchor and the Negative. Furthermore, the authors introduce an Adaptive Learning Objective. Instead of simply equating an idiom with its paraphrase, the model learns that the semantic relationship between an idiom and a wrong paraphrase should mirror the relationship between a correct paraphrase and that same wrong paraphrase.
Semantic Meaning Miner
To ensure the model learns effectively, the authors implemented a "miner" to identify "hard" negatives. By calculating Euclidean distances between embeddings within a batch, the miner selects negatives that are surface-level similar but semantically distinct. This prevents the model from converging on "easy" solutions and forces it to discern figurative nuances.
Experimental Setup and Datasets
The research utilizes the SemEval-2022 Task 2B dataset, comprising approximately 8,600 annotated examples. The study is multilingual, focusing on English (EN), Portuguese (PT), and Galician (GL). To help the model break compositional habits, idioms are treated as single units during preprocessing (e.g., replacing "home run" with a unique token like IDhomerunID).
Key Results
The models were evaluated using Spearman’s rank correlation ($\rho$) to compare model-generated similarity scores with human judgments.
Performance Comparison
The proposed 558M parameter model achieved state-of-the-art results, significantly outperforming much larger general-purpose models. Notably, it achieved a score of 0.548 on the "Idiom Only" subset, compared to 0.171 for the 13-billion-parameter Llama 2.
Multilingual Generalization
The method demonstrated robust performance across languages. The model achieved a correlation of $\rho=0.757$ in English and $\rho=0.707$ in Portuguese. Furthermore, the training process provided a massive boost to base models; for instance, an xlm-roberta-large model improved its idiom score from 0.138 to 0.484 after applying the triplet loss method.
Discussion and Insights
The findings suggest two major takeaways for the NLP community:
- Size is not a substitute for specialization: The fact that a 558M parameter model outperformed Llama 2 (13B) by a wide margin on idiomatic tasks indicates that general-purpose pre-training does not inherently solve the problem of non-compositional language.
- The Compositionality Bias: Sub-word tokenization, while efficient, reinforces literal interpretations. By explicitly training models to treat idioms as distinct semantic units, the "asymmetric contribution" of words within an idiom can be properly represented.
Limitations and Future Work
Despite its success, the current pipeline relies on idioms being pre-identified in the text. Future research should focus on integrated detection and representation. Additionally, while the model excels at representing the idiom's meaning, further work is needed to improve contextual sensitivity—distinguishing between literal and figurative uses of the same phrase based on surrounding context.
Summary updated