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.

相关推荐
HySpark2 分钟前
语音输入法实践:Rust 集成 Paraformer 推理引擎踩坑与优化过程
人工智能·后端·语音识别·熙瑾会悟
不爱土豆唯爱马铃薯7 分钟前
用MonkeyCode做一个野外数据采集表 | MonkeyCode实操系列EP06
人工智能·数据分析
董员外8 分钟前
RAG 系统进化论(九):RAG 评测,怎样证明系统真的变好了?
人工智能·设计模式·程序员
IT小盘17 分钟前
10-使用Reranker提升RAG回答准确率
人工智能·python
小黑技术栈21 分钟前
DevEco Code Plan+Build模式:审方案再执行的技术实践
人工智能
Thom58024 分钟前
【聚宽 JoinQuant】聚宽如何获取持仓和订单?get_orders()与get_open_orders()教程
人工智能·经验分享·量化交易·聚宽·量化编程
EasyDSS26 分钟前
景区客流遇冷?用EasyDSS企业融媒体平台直播/点播解锁「云上文旅」新玩法
人工智能·媒体·直播·点播·easydss
刘一说29 分钟前
AI科技热点日报 | 2026年08月04日
人工智能·科技
如此这般英俊38 分钟前
手搓Claude Code-第十章 system_prompt
数据结构·人工智能·python·语言模型·自然语言处理·prompt
云端漫步198739 分钟前
HarmonyOS NEXT AI 智能生活助手:AI 日程规划
人工智能·华为·生活·harmonyos