[Paper Review] Few-Shot Nested Named Entity Recognition
This paper proposes a Biaffine-based Contrastive Learning (BCL) framework for few-shot nested named entity recognition, leveraging span dependency representations and contrastive learning to distinguish nested entities with limited labeled data. The method achieves state-of-the-art performance on English, German, and Russian datasets, outperforming baselines by up to 5.57% in F1 score under 5-shot settings.
While Named Entity Recognition (NER) is a widely studied task, making inferences of entities with only a few labeled data has been challenging, especially for entities with nested structures. Unlike flat entities, entities and their nested entities are more likely to have similar semantic feature representations, drastically increasing difficulties in classifying different entity categories in the few-shot setting. Although prior work has briefly discussed nested structures in the context of few-shot learning, to our best knowledge, this paper is the first one specifically dedicated to studying the few-shot nested NER task. Leveraging contextual dependency to distinguish nested entities, we propose a Biaffine-based Contrastive Learning (BCL) framework. We first design a Biaffine span representation module for learning the contextual span dependency representation for each entity span rather than only learning its semantic representation. We then merge these two representations by the residual connection to distinguish nested entities. Finally, we build a contrastive learning framework to adjust the representation distribution for larger margin boundaries and more generalized domain transfer learning ability. We conducted experimental studies on three English, German, and Russian nested NER datasets. The results show that the BCL outperformed three baseline models on the 1-shot and 5-shot tasks in terms of F1 score.
Motivation & Objective
- To address the challenge of recognizing nested named entities when only a few labeled examples are available.
- To overcome the difficulty of distinguishing nested entities due to shared semantic representations in low-resource settings.
- To improve generalization and domain transfer in few-shot learning by learning more discriminative span representations.
- To mitigate label discrepancy issues in transfer learning across domains with inconsistent label spaces.
- To validate the effectiveness of the proposed framework on multilingual nested NER datasets.
Proposed method
- A Biaffine span representation module is designed to learn contextual dependency patterns between words within and across entity spans.
- The model fuses word-level semantic representations with span-level dependency representations via residual connections to enhance discriminability.
- A contrastive learning objective with circle loss is applied to push apart positive span pairs and increase margin boundaries in representation space.
- The framework uses a multilingual pre-trained language model (BERT-base-multilingual) for cross-lingual transfer and domain adaptation.
- The model is trained end-to-end using a support set of only 1–5 labeled examples per entity type, with inference performed on a query set.
- A bias term is introduced in the contrastive loss to emphasize the most dissimilar positive span pairs, improving representation learning.

Experimental results
Research questions
- RQ1Can a few-shot learning framework effectively recognize nested named entities when only one or a few labeled examples are available?
- RQ2How can span-level dependency representations improve the distinction between nested and flat entities in low-resource settings?
- RQ3To what extent does contrastive learning with a margin-based loss enhance generalization and domain transfer in few-shot nested NER?
- RQ4How does the integration of biaffine structures and residual connections affect performance on nested entity recognition?
- RQ5Does the proposed framework generalize across languages, particularly across Indo-European language families?
Key findings
- The BCL framework outperforms three baseline models on all three datasets (English, German, Russian) in both 1-shot and 5-shot settings, achieving a 5.57% absolute F1 improvement over baselines in the 5-shot setting on the GENIA dataset.
- The ablation study shows the Biaffine layer contributes the most to performance, improving F1 by 1.73% and 5.57% in 1-shot and 5-shot settings, respectively.
- Removing the residual connection between semantic and dependency representations reduces F1 by 1.76% and 1.29% in 1-shot and 5-shot, respectively, indicating its importance in representation fusion.
- Including the bias term in the contrastive loss increases F1 by 1.38% and 2.05% in 1-shot and 5-shot, respectively, showing improved focus on hard positive pairs.
- Using the multilingual BERT model yields slightly lower performance than the cased English BERT on English datasets, but the difference is minimal, supporting the use of multilingual models for cross-lingual transfer.
- In flat NER benchmarks, BCL achieves competitive results, especially in the 5-shot setting, though performance gaps appear in 1–2 shot settings due to limited positive samples for distribution learning.

Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.