NLP Bi-Encoder和Re-ranker

Retrieve & Re-Rank

https://www.sbert.net/examples/applications/retrieve_rerank/README.html

Bi-Encoder vs. Cross-Encoder

https://www.sbert.net/examples/applications/cross-encoder/README.html

Bi-Encoder会用BERT对输入文本编码,再根据cosine相似度分数筛选文本。Cross-Encoder会直接计算两个句子的相关性分数。

如何将BI和Cross Encoder配合使用?可以先用BI-Encoder选出top 100个候选项,再用Cross-Encoder挑选最佳选项。

Combining Bi- and Cross-Encoders

Cross-Encoder achieve higher performance than Bi-Encoders, however, they do not scale well for large datasets.

Here, it can make sense to combine Cross- and Bi-Encoders, for example in Information Retrieval / Semantic Search scenarios:

First, you use an efficient Bi-Encoder to retrieve e.g. the top-100 most similar sentences for a query.

Then, you use a Cross-Encoder to re-rank these 100 hits by computing the score for every (query, hit) combination.

相关推荐
用户5191495848451 分钟前
WordPress Portfolleo 插件漏洞利用工具 (CVE-2024-49653)
人工智能·aigc
俊哥V1 分钟前
每日 AI 研究简报 · 2026-05-13
人工智能·ai
用户4330514143812 分钟前
和 TypeScript / Node 交互
人工智能
Wanderer X2 分钟前
【LLM】RAG mRAG
人工智能
eastyuxiao5 分钟前
数字孪生教程(软件篇)官方学习路径
大数据·人工智能·学习·数字孪生
茉莉玫瑰花茶6 分钟前
LangGraph 入门教程:构建 AI 工作流 [ 案例三 ]
前端·人工智能·python
我有医保我先冲7 分钟前
【无标题】
java·大数据·人工智能
染指111011 分钟前
2.AI大模型-链式思考TOC让AI实现思考-优秀提示词设计技巧
大数据·数据库·人工智能
Daydream.V11 分钟前
从零搭建 AI Agent:LLM Agent+Function Calling+Dify 本地部署 + Coze 实战全攻略
人工智能·langchain·ollama·functioncalling·大模型部署
数据智研13 分钟前
【数据分享】中国第三产业统计年鉴(1991-2025)(1993-1994、2001-2005末出版)
大数据·人工智能·信息可视化·数据分析