Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

【论文复现】SGPT #6618

Closed
shiyutang opened this issue Aug 4, 2023 · 2 comments
Closed

【论文复现】SGPT #6618

shiyutang opened this issue Aug 4, 2023 · 2 comments
Assignees
Labels
others unknown issue type triage

Comments

@shiyutang
Copy link

shiyutang commented Aug 4, 2023

背景

GPT transformers是可用的最大的语言模型,但语义搜索由BERT Transformers主导。本文提供SGPT-BE和SGPT-CE以应用GPT模型作为对称或非对称的Bi-Encoders或Cross-Encoders搜索。
SGPT-BE通过对比产生语义上有意义的句子嵌入仅偏置张量的微调和一种新的池化方法。58亿参数SGPT-BE在BEIR上的表现优于最佳可用句子嵌入7%,达到了SOTA的水平。它优于同时提出的1750亿参数Davinci端点的OpenAI嵌入,后者微调了250000倍以上的参数。
SGPT-CE在没有任何微调的情况下使用来自GPT模型的对数概率。61亿参数的SGPT-CE在BEIR上设置了无监督的最先进技术。它在7个数据集上击败了有监督的SOTA方法,但在其他数据集上明显落后。论文展示了如何通过调整提示来缓解这种情况。

解决步骤:

  1. 根据开源代码进行网络结构、评估指标转换。代码链接:https://github.com/Muennighoff/sgpt/tree/main
  2. 结合论文复现指南,进行前反向对齐等操作,达到论文Table.1,Table 6中的指标,训练代码使用paddlenlp的trainer实现。(其中基础模型例如goundingdino等可以参考ppnlp和paddlemix)
  3. 参考PR提交规范提交代码PR到paddlenlp中。
@qiuwenbogdut
Copy link
Contributor

image

GPT-BE 比 BM25-CE 平均好三个点,而且并不是全部数据集都比bm25-ce要好.
而且GPT-BE 的模型参数量达到了5.8B

实际落地的时候, GPT-BE 大模型表征一次的耗时估计也不短.

请教个问题, 实际落地的时候什么样的情况下选择GPT-BE这个方案会比较好? @shiyutang

@w5688414
Copy link
Contributor

w5688414 commented Aug 7, 2023

image GPT-BE 比 BM25-CE 平均好三个点,而且并不是全部数据集都比bm25-ce要好. 而且GPT-BE 的模型参数量达到了5.8B

实际落地的时候, GPT-BE 大模型表征一次的耗时估计也不短.

请教个问题, 实际落地的时候什么样的情况下选择GPT-BE这个方案会比较好? @shiyutang

这个方案是想释放LLM的检索能力,这个实际可以根据速度优先和效果优先,灵活选取。如果是速度优先,GPT-BE明显不太适合,如果效果优先,可以考虑一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
others unknown issue type triage
Projects
None yet
Development

No branches or pull requests

4 participants