Abstract
Figurative language detection has traditionally been treated as a series of isolated tasks, with models specialized for specific figures of speech or individual languages. This paper presents a unified framework developed by researchers at the University of Groningen that leverages the mT5 transformer and prompt-based learning to detect metaphors, idioms, and hyperboles across seven languages. By treating figurative language detection as a generative text-to-text task, the model enables cross-figurative and cross-lingual knowledge transfer, significantly outperforming traditional task-specific baselines.
Introduction
Figurative language—encompassing metaphors, idioms, and hyperboles—is a fundamental component of human communication, yet it remains a significant challenge for Natural Language Processing (NLP). Most existing detection systems operate in silos, trained for a single figure of speech in a single language (predominantly English). This approach creates two primary gaps: a multilingual gap, where cultural nuances are lost, and a multi-figurative gap, where models fail to leverage the shared conceptual properties between different types of non-literal language.
To address these limitations, this research proposes a multitask, multilingual framework that treats figurative language detection as a unified generative task. The goal is to determine if a single model can effectively learn the underlying "logic" of non-literalness across diverse linguistic and figurative contexts.
Methodology
Model Architecture
The researchers utilized mT5 (Multilingual T5), a text-to-text transformer, as the backbone of their system. Unlike traditional classification models that require task-specific architecture (such as a classification head), this approach reformulates detection into a natural language generation task using Template-Based Prompt Learning.
Prompt-Based Learning
Every detection task is converted into a natural language question. For example, the model might be prompted with: "Which figure of speech does this text contain? (A) Literal. (B) Idiom. | Text: [Input Sentence]". The model is then tasked with generating the string "Idiom" or "Literal" as its output. This strategy allows the model to navigate a shared semantic space across seven different languages.
Multitask Training
The framework employs multitask training, where the model is trained simultaneously on all available datasets. This allows for "cross-figurative transfer," where the model's understanding of one figure (e.g., metaphors) informs its ability to detect others (e.g., hyperboles).
Experimental Setup
The study utilizes five datasets covering three figures of speech and seven languages:
- Hyperbole: HYPO (English) and HYPO-cn (Chinese).
- Idiom: ID10M (English, German, Spanish, Italian), converted to sentence-level labels.
- Metaphor: LCC (English, Spanish, Farsi, Russian).
Key Findings
The Power of Cross-Figurative Transfer
A primary insight of the study is that training on metaphors significantly aids the detection of hyperboles and idioms. Metaphors appear to provide a foundational understanding of non-literalness that generalizes across figurative types. This suggests that figurative language, despite its variety, shares a common cognitive or linguistic root that a unified model can capture.
Performance Gains
The Prompt mT5 + Multitask model achieved superior results compared to standard baselines. In English hyperbole detection, the model reached 82.00% accuracy, a substantial improvement over the 72.33% achieved by the mBERT baseline. Furthermore, the model demonstrated robust zero-shot capabilities. When trained exclusively on English data, it maintained over 68% accuracy in detecting metaphors and hyperboles in other languages, proving that figurative logic transcends language barriers.
Language Synergy
The multitask approach proved particularly beneficial for languages with smaller datasets, such as Chinese. By "borrowing" knowledge from larger English datasets, the model achieved higher performance on low-resource languages than would be possible with single-language training.
Discussion and Limitations
While the unified model shows great promise, several challenges remain:
- Granularity: The current work focuses on sentence-level detection. Future research is needed to move toward word-level detection to identify specific figurative components.
- Data Quality: The reliance on "silver" (automatically generated) training data for idioms led to a performance gap when tested against "gold" (human-annotated) data. High-quality, human-labeled multilingual datasets are essential for further progress.
- Cultural Ceiling: Some idioms are so deeply rooted in specific cultural contexts that cross-lingual transfer hits a performance ceiling, suggesting a need for integrated cultural knowledge bases.
Conclusion
This research demonstrates that a unified, prompt-based generative model can effectively bridge the gaps between different figures of speech and multiple languages. By moving away from task-specific silos, the mT5-based framework provides a more holistic and efficient approach to understanding the complexities of human figurative expression in NLP.
Summary updated