NER Retriever: Zero-Shot Named Entity Retrieval with Type-Aware Embeddings
NER Retriever提出了一种基于类型感知嵌入的零样本命名实体检索框架,通过利用大型语言模型(LLM)的内部表示,实现了对未知实体类型的有效检索。
更新于 2025-09-10。作者:Or Shachar、Uri Katz、Yoav Goldberg、Oren Glickman。
中文摘要
我们提出了一种名为 NER Retriever 的零样本检索框架,用于临时命名实体检索,这是一种命名实体识别(NER)的变体。在这种检索中,感兴趣的类型不是预先提供的,而是使用用户定义的类型描述来检索提及该类型实体的文档。我们的方法不依赖于固定的模式或微调模型,而是基于大型语言模型(LLM)的内部表示,将实体提及和用户提供的开放式类型描述嵌入到一个共享的语义空间中。我们发现,内部表示,特别是来自中间层变换器块的值向量,比常用的顶层嵌入更有效地编码了细粒度的类型信息。为了细化这些表示,我们训练了一个轻量级的对比投影网络,该网络在保持类型兼容实体对齐的同时,将无关类型分开。生成的实体嵌入紧凑、类型感知,非常适合最近邻搜索。在三个基准测试中,NER Retriever 显著优于词汇和密集句子级检索的基线。我们的发现为 LLM 中的表示选择提供了经验支持,并展示了一个可扩展、无模式实体检索的实际解决方案。NER Retriever 代码库在 https://github.com/ShacharOr100/ner_retriever 公开可用。
英文摘要
We present NER Retriever, a zero-shot retrieval framework for ad-hoc Named Entity Retrieval, a variant of Named Entity Recognition (NER), where the types of interest are not provided in advance, and a user-defined type description is used to retrieve documents mentioning entities of that type. Instead of relying on fixed schemas or fine-tuned models, our method builds on internal representations of large language models (LLMs) to embed both entity mentions and user-provided open-ended type descriptions into a shared semantic space. We show that internal representations, specifically the value vectors from mid-layer transformer blocks, encode fine-grained type information more effectively than commonly used top-layer embeddings. To refine these representations, we train a lightweight contrastive projection network that aligns type-compatible entities while separating unrelated types. The resulting entity embeddings are compact, type-aware, and well-suited for nearest-neighbor search. Evaluated on three benchmarks, NER Retriever significantly outperforms both lexical and dense sentence-level retrieval baselines. Our findings provide empirical support for representation selection within LLMs and demonstrate a practical solution for scalable, schema-free entity retrieval. The NER Retriever Codebase is publicly available at https://github.com/ShacharOr100/ner_retriever
解读
一句话总结
NER Retriever提出了一种基于类型感知嵌入的零样本命名实体检索框架,通过利用大型语言模型(LLM)的内部表示,实现了对未知实体类型的有效检索。
问题1:这篇论文想要解决什么具体问题?
- 问题背景:传统的命名实体识别(NER)系统通常依赖于预定义的实体类型,限制了其在处理多样化、特定领域实体类型时的适用性。
- 现有方案不足:现有命名实体检索方法在处理未知实体类型时效果不佳,且缺乏对开放性、细粒度实体类型的支持。
- 研究目标:开发一种零样本命名实体检索框架,能够检索用户定义的任意类型实体,并有效处理未知实体类型。
问题2:论文的核心创新点是什么?
- 技术创新:利用LLM的内部表示,特别是中间层的值向量,作为实体嵌入,有效编码细粒度类型信息。
- 方法改进:通过对比学习训练轻量级投影网络,使类型兼容的实体聚集在一起,同时分离不相关的类型。
- 优势:相比现有方法,NER Retriever能够更精确地检索未知实体类型,且无需针对特定任务对LLM进行微调。
问题3:实验结果如何验证了方法的有效性?
- 关键实验:在Few-NERD、MultiCoNER 2和NERetrieve三个基准数据集上评估NER Retriever的性能。
- 性能提升:NER Retriever在大多数情况下显著优于基于词汇和密集句子级检索的基线方法。
- 对比结果:与BM25和E5-Mistral等基线方法相比,NER Retriever在Few-NERD和MultiCoNER 2上实现了更高的R-Precision。
问题4:这个研究的实际应用价值是什么?
- 应用场景:信息检索、问答系统和知识库构建等领域,能够处理用户定义的任意类型实体检索。
- 实施建议:结合领域特定知识或数据对LLM进行微调,以提高在特定领域的性能。
- 局限与展望:NER Retriever在特定领域(如法律、医学或金融)的性能可能受限,未来研究可探索领域自适应LLM或微调方法。
来源
机器可读索引:llms.txt