Introduction
Document-level relation extraction (RE) is a complex task that requires identifying relationships between entities whose mentions are scattered across multiple sentences. Unlike sentence-level RE, which focuses on local context, document-level RE must account for coreferences and long-range dependencies. The Structured Self-Attention Network (SSAN) addresses this by explicitly integrating entity structures—such as coreference and sentence boundaries—directly into the Transformer's attention mechanism.
The Challenge of Document-Level RE
Standard Transformer models like BERT or RoBERTa are highly effective at capturing general context but lack an inherent understanding of entity-level structures. For instance, they do not automatically recognize that different mentions (names, pronouns, or descriptions) refer to the same entity node unless specifically trained to do so.
Previous attempts to incorporate this structure often relied on pre-processing or post-processing steps, such as adding graph neural networks on top of BERT. However, these methods tend to isolate contextual reasoning from structural reasoning. SSAN overcomes this by baking structure "within and throughout" the encoding process.
The SSAN Architecture
SSAN formalizes dependencies between any two tokens based on two primary axes: co-occurrence (intra-sentence vs. inter-sentence) and coreference (same entity vs. different entities). This framework results in four main dependency types, such as inter+coref or intra+relate.
In a standard Transformer, attention is calculated via a query-key product. SSAN modifies this by adding a structural bias:
$$\text{Attention Score} = \text{Standard Attention} + \text{Transformation}(\text{Query, Key, Dependency Type})$$
The authors propose two transformation modules: a sophisticated Biaffine Transformation and a more efficient Decomposed Linear Transformation. These biases allow the model to adaptively regularize its attention flow based on the structural relationship between tokens.
Key Results and Insights
SSAN was evaluated on major benchmarks including DocRED, CDR, and GDA, consistently outperforming competitive baselines:
- DocRED: SSAN built on RoBERTa-Large achieved an F1 score of 62.08, rising to 65.92 with distant supervision adaptation.
- Biomedical Gains: On the CDR dataset, SSAN provided a +2.9 F1 gain over SciBERT, proving its utility in specialized domains.
- The "Bridge" Effect: Analysis revealed that
intra+corefdependencies (mentions of the same entity in the same sentence) act as a crucial bridge for linking disparate information across the document. - Layer-wise Evolution: Visualization showed that while lower layers focus on general semantics, structural biases become significantly stronger in the top-most layers, where final relational reasoning occurs.
Conclusion
By treating entity structure as an inductive bias rather than an external feature, SSAN provides a roadmap for the attention mechanism. This approach significantly improves the model's ability to perform cross-sentence reasoning, setting a new standard for document-level relation extraction.
Summary updated