Introduction
Relation Extraction (RE) is a fundamental task in Natural Language Processing, involving the identification of semantic relationships between entities in text. For instance, given the sentence "Paris is the birthplace of Victor Hugo," an RE model should identify the place of birth relation between "Victor Hugo" and "Paris." While state-of-the-art language models achieve impressive scores on standard benchmarks, there is growing concern that these models rely on "pattern matching"—overfitting to dataset-specific artifacts and spurious correlations—rather than learning the underlying semantic concepts. This study investigates the "generalization gap": the significant performance decline observed when models trained on one RE dataset are evaluated on another, even within the same domain.
Methodology
The researchers evaluated two primary architectures: the encoder-only DeBERTa-v3-large and the decoder-only LLaMA 3.1 8B. They explored three adaptation strategies:
- Full Fine-tuning: Applied to DeBERTa.
- Parameter-Efficient Fine-tuning (PEFT): Utilizing LoRA for LLaMA.
- In-Context Learning (ICL): Testing LLaMA in zero-shot and 5-shot configurations.
To facilitate cross-dataset evaluation, the authors manually mapped labels across three benchmarks—TACRED-RE, NYT, and Biographical—to create a unified "biographical" relation space. This involved standardizing labels like TACRED's per:city_of_birth into a broader place_of_birth category. Data formats were standardized using entity markers to ensure consistency across models and datasets.
Datasets
The study focused on biographical relations (e.g., birth, death, family) across three distinct datasets:
- TACRED-RE: A high-quality, manually curated dataset derived from news and web text.
- NYT (New York Times): A distantly supervised dataset where relations are automatically inferred from knowledge bases, introducing significant noise.
- Biographical: A semi-supervised dataset constructed from Wikipedia articles.
The Generalization Gap
A key finding is the "performance mask": high in-distribution scores often hide a failure to generalize. A model might achieve an 0.87 F1 score on its training set but plummet to 0.26 when tested on a different dataset. This suggests that models are learning the specific "quirks" of a dataset rather than the abstract task of relation extraction.
As shown in the confusion matrices above, models fine-tuned on the noisy NYT dataset tend to over-predict the "None" class when evaluated on other datasets. This behavior likely stems from NYT's distant supervision, which often fails to label valid relations, teaching the model that unfamiliar phrasing implies no relation exists.
Key Results
The experimental results confirm a systematic 20-30 point drop in F1 scores during cross-dataset evaluation.
The data indicates that data quality is a more significant driver of robustness than lexical similarity. Models trained on the high-quality TACRED-RE dataset generalized significantly better to the Wikipedia-based Biographical dataset than those trained on the noisy NYT dataset, despite both TACRED and NYT being news-based. Furthermore, for noisy datasets like NYT, few-shot In-Context Learning (ICL) often outperformed fine-tuning, as fine-tuning tends to "bake in" the training set's noise, whereas ICL leverages the model's pre-trained semantic knowledge.
Discussion and Limitations
The study highlights the "Single Relation Trap": most benchmarks enforce a single relation per sentence, which confuses models when encountering real-world sentences containing multiple valid relations. Additionally, the definition of the "None" (no relation) class varies significantly across datasets, making it the hardest class for generalization.
Future research should focus on finer-grained word evidence (rationales) to ensure models attend to relevant keywords and test robustness against adversarial perturbations. While this study focused on biographical relations, extending this analysis to technical domains like medical or legal RE remains an important next step.
Summary updated