Abstract
AlignRE is a novel framework for Zero-Shot Relation Extraction (ZSRE) designed to bridge the "encoding gap" between sentence representations and relation definitions. By utilizing a unified prompt-tuning approach and intelligently aggregating multiple sources of side information—such as relation aliases and label names—AlignRE achieves state-of-the-art performance on standard benchmarks. Notably, it remains significantly faster than generation-based alternatives, offering a robust solution for extracting unseen relations in dynamic environments.
Introduction
Relation Extraction (RE) involves identifying semantic relationships between entities within a sentence. Zero-Shot Relation Extraction (ZSRE) extends this challenge by requiring models to identify relations not seen during training, relying instead on auxiliary knowledge like textual descriptions.
Existing prototype-based ZSRE methods suffer from two primary limitations:
- The Encoding Gap: There is often a mathematical mismatch between how sentences are represented (e.g., feature concatenation) and how relation "prototypes" are encoded (e.g., averaging word embeddings of descriptions). This mismatch hinders the model's ability to accurately match sentences to their corresponding relations.
- Underutilized Side Information: Models frequently rely on a single text description, ignoring rich metadata like formal label names and semantic aliases (e.g., "member of" vs. "plays for"), which can provide a cleaner signal than noisy descriptions.
Methods
AlignRE addresses these flaws through two integrated modules: Encoding alignment-based Sentence Representation (EaSR) and Semantic alignment-based Relation Prototype Aggregation (SaPA).
Encoding alignment-based Sentence Representation (EaSR)
To eliminate the encoding gap, AlignRE adopts a unified prompt template for both sentences and prototypes. For an input sentence, it constructs a prompt: "The relation between [MASK]h [Head Entity] and [MASK]t [Tail Entity] is [MASK]r." Embeddings are extracted specifically from these [MASK] tokens. By using a similar schema for prototype encoding, the model ensures that both representations reside in a compatible feature space, allowing for direct similarity matching.
Semantic alignment-based Relation Prototype Aggregation (SaPA)
Rather than relying on a single description, SaPA aggregates diverse side information, including label names, descriptions, and aliases. It employs an attention-based semantic alignment mechanism to weight these inputs, creating a robust "super-prototype" embedding that captures the multifaceted nature of a relation while filtering out noise from longer descriptions.
Results
The authors evaluated AlignRE on the FewRel and Wiki-ZSL benchmarks across varying numbers of unseen relations ($m=5, 10, 15$).
Performance and Stability
AlignRE consistently outperformed previous state-of-the-art (SOTA) methods, including RE-Matching and SUMASK. It achieved an average F1 improvement of +2.33 on FewRel and +1.47 on Wiki-ZSL. Furthermore, its performance remained stable as the number of unseen relations increased, whereas competing models often showed significant degradation. Aligning the encoding schema alone yielded a massive F1 improvement of nearly 33 points in some configurations compared to traditional concatenation methods.
Efficiency
In addition to accuracy, AlignRE demonstrates superior inference speed. By relying on direct embedding matching rather than the complex token generation required by Large Language Models (LLMs), it processes sentences significantly faster while maintaining higher precision in zero-shot scenarios.
Conclusion
AlignRE demonstrates that aligning encoding schemas is as critical as the quality of the input data itself. By bridging the encoding gap and effectively leveraging multifaceted side information, it sets a new standard for Zero-Shot Relation Extraction. Future work may explore the model's scalability to hundreds of unseen relations and the potential for automated prompt engineering to further refine performance.
Summary updated