Optimizing Bi-Encoder for Named Entity Recognition via Contrastive Learning
Sheng Zhang, Hao Cheng, Jianfeng Gao, Hoifung Poon
Abstract
We present a bi-encoder framework for named entity recognition (NER), which applies contrastive learning to map candidate text spans and entity types into the same vector representation space. Prior work predominantly approaches NER as sequence labeling or span classification. We instead frame NER as a representation learning problem that maximizes the similarity between the vector representations of an entity mention and its type. This makes it easy to handle nested and flat NER alike, and can better leverage noisy self-supervision signals. A major challenge to this bi-encoder formulation for NER lies in separating non-entity spans from entity mentions. Instead of explicitly labeling all non-entity spans as the same class Outside (O) as in most prior methods, we introduce a novel dynamic thresholding loss, learned in conjunction with the standard contrastive loss. Experiments show that our method performs well in both supervised and distantly supervised settings, for nested and flat NER alike, establishing new state of the art across standard datasets in the general domain (e.g., ACE2004, ACE2005, CoNLL2003) and high-value verticals such as biomedicine (e.g., GENIA, NCBI, BC5CDR, JNLPBA). We release the code at github.com/microsoft/binder.
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
7 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- NuNER: Entity Recognition Encoder Pre-training via LLM-Annotated Data cites GoLLIE: Annotation Guidelines improve Zero-Shot Information-Extraction
- Improving Natural Language Understanding for LLMs via Large-Scale Instruction Synthesis cites GoLLIE: Annotation Guidelines improve Zero-Shot Information-Extraction
- PaDeLLM-NER: Parallel Decoding in Large Language Models for Named Entity Recognition cites GoLLIE: Annotation Guidelines improve Zero-Shot Information-Extraction
Cited by top-tier papers7
- GoLLIE: Annotation Guidelines improve Zero-Shot Information-ExtractionOscar Sainz, Iker García-Ferrero, Rodrigo Agerri, Oier Lopez de Lacalle et al.ICLR 2024 · 168 citations
- NuNER: Entity Recognition Encoder Pre-training via LLM-Annotated DataSergei Bogdanov, Alexandre Constantin, Timothée Bernard, Benoît Crabbé et al.EMNLP 2024 · 29 citations
- PaDeLLM-NER: Parallel Decoding in Large Language Models for Named Entity RecognitionJinghui Lu, Yanjie Wang, Ziwei Yang, Xuejing Liu et al.NeurIPS 2024 · 22 citations
- Improving Natural Language Understanding for LLMs via Large-Scale Instruction SynthesisLin Yuan, Jun Xu, Honghao Gui, Mengshu Sun et al.AAAI 2025 · 3 citations
- Span Graph Transformer for Document-Level Named Entity RecognitionHongli Mao, Xian-Ling Mao, Hanlin Tang, Yuming Shang et al.AAAI 2024 · 3 citations
Builds on21
- Supervised Contrastive LearningPrannay Khosla, Piotr Teterwak, Chen Wang, Aaron Sarna et al.NeurIPS 2020 · 7,049 citations
- A Unified MRC Framework for Named Entity RecognitionXiaoya Li, Jingrong Feng, Yuxian Meng, Qinghong Han et al.ACL 2020 · 617 citations
- LinkBERT: Pretraining Language Models with Document LinksMichihiro Yasunaga, Jure Leskovec, Percy LiangACL 2022 · 463 citations
- Template-Based Named Entity Recognition Using BARTLeyang Cui, Yu Wu, Jian Liu, Sen Yang et al.ACL Findings 2021 · 342 citations
- Scalable Zero-shot Entity Linking with Dense Entity RetrievalLedell Wu, Fabio Petroni, Martin Josifoski, Sebastian Riedel et al.EMNLP 2020 · 336 citations
Related papers
- Focusing, Bridging and Prompting for Few-shot Nested Named Entity RecognitionYuanyuan Xu, Zeng Yang, Linhai Zhang, Deyu Zhou et al.ACL Findings 2023 · 10 citations
- Improving Named Entity Recognition via Bridge-based Domain AdaptationJingyun Xu, Changmeng Zheng, Yi Cai, Tat-Seng ChuaACL Findings 2023 · 3 citations
- Boundary Enhanced Neural Span Classification for Nested Named Entity RecognitionChuanqi Tan, Wei Qiu, Mosha Chen, Rui Wang et al.AAAI 2020 · 125 citations
- Noise-Robust Training with Dynamic Loss and Contrastive Learning for Distantly-Supervised Named Entity RecognitionZhiyuan Ma, Jintao Du, Shuheng ZhouACL Findings 2023 · 4 citations
- Learning "O" Helps for Learning More: Handling the Unlabeled Entity Problem for Class-incremental NERRuotian Ma, Xuanting Chen, Zhang Lin, Xin Zhou et al.ACL 2023 · 12 citations
