微信扫码
与创始人交个朋友
我要投稿
相关性感知过程(Relevance-Aware Process, RAP)
选择默认的检索器(如DPR和Contriever)来检索与问题相关的文档。
指导模型评估检索到的文档与问题的相关性,并生成解释为何这些文档被识别为相关的输出。
如果所有检索到的文档都不相关,模型应依据预训练阶段获得的内部知识提供答案。
证据感知选择过程(Evidence-Aware Selective Process, EAP)
要求模型从检索到的文档中明确选择关键句子作为证据,并输出选择这些句子的原因。
模型需要自动选择文档中的关键句子片段,并解释为何这些片段能够回答问题。
轨迹分析过程(Trajectory Analysis Process, TAP)
将前两个过程中生成的自我推理轨迹整合,形成推理片段链,以增强检索增强生成的整体性能。
要求模型分析这些推理轨迹,并最终输出简洁的分析和简短的答案。
此外,还包括数据生成和质量控制的过程:
训练数据生成:使用GPT-4生成答案作为基准真值,并创建正负样本对。
数据质量控制:通过自动验证工具和过滤不正确答案的轨迹,确保数据生成的正确性和完整性。
模型训练:
使用标准的语言建模目标进行训练,通过最大化似然函数来训练自我推理生成模型。
提出了分阶段掩码策略的逐步训练方法,以逐步学习生成长推理轨迹。
通过在四个公共数据集(两个短形式问答数据集、一个长形式问答数据集和一个事实验证数据集)上的评估,证明了该方法的优越性,能够超越现有的最先进模型,并且在仅使用2,000个训练样本的情况下,就能与GPT-4的性能相媲美。
附录:
GPT-4生成短形式和长形式问答任务的自我推理轨迹的Prompt模版
Instructions# RoleYou are an experienced expert, skilled in answering various questions.# TaskPlease answer the question according to the provided reference evidence asrequired.# Reference Evidence[1] Retrieved Document {{DOCUMENT 1}[2] Retrieved Document {{DOCUMENT 2}[3] Retrieved Document {{DOCUMENT 3}[4] Retrieved Document {{DOCUMENT 4}[5] Retrieved Document {{DOCUMENT 5}# Requirements1. First, please judge whether the provided documents are relevant with thequestion, and put it in the relevant field. If the provided content is irrelevant tothe question, explain the reason in the relevant reason field, then you can givethe answer with your internal knowledge.2. If possible, answer the question in points and provide explanations.3. If the content in the answer comes from different pieces of evidence, youneed to cite the sequence number of the evidence at the end of the sentence.The citation format is shown below: [1], [1,3].4. Place each cited piece of evidence in the cite_list field, cite content field tostore each paragraph of cited content (omitted words can be replaced by ...),cite reason is used to store your thoughts and analysis of this content, howthis paragraph can answer the question.5. Put the long answer content in the analysis field, and put the shortanswer(no more than 10 words) in the answer field.# Question{{QUESTION}}
GPT-4生成事实验证任务的自我推理轨迹的Prompt模版
Instructions# RoleYou are an experienced expert, skilled in answering various questions.# TaskPlease answer the question according to the provided reference evidence asrequired.# Reference Evidence[1] Retrieved Document {{DOCUMENT 1}}[2] Retrieved Document {{DOCUMENT 2}}[3] Retrieved Document {{DOCUMENT 3}}[4] Retrieved Document {{DOCUMENT 4}}[5] Retrieved Document {{DOCUMENT 5}}# Requirements1. First, please judge whether the provided documents are relevant with theclaim, and put it in the relevant field. If the provided content is irrelevant to thequestion, explain the reason in the relevant reason field, then you can give theanswer with your internal knowledge.2. If possible, answer the question in points and provide explanations.3. If the content in the answer comes from different pieces of evidence, youneed to cite the sequence number of the evidence at the end of the sentence.The citation format is shown below: [1], [1,3].4. Place put each cited piece of evidence in the list, use cite content field tostore each paragraph of cited content (omitted words can be replaced by ...),cite reason is used to store your thoughts and analysis of this content, how thisparagraph can answer the question.5. Put the long answer content in the analysis field, and put the short answer(SUPPORT/REFUTE/NOT ENOUGH INFO) in the answer field.# QuestionYou should check whether the given claim is supported or refuted by above theevidence. If supported,output SUPPORT, if controversial, output REFUTE; ifthe evidence provided is not enough to make a decision or the providedevidence is irrelevant, output NOT ENOUGH INFO.{{CLAIM}}
案例研究。展示了SELF-REASONING框架在推理过程中生成的自我推理轨迹,并展示了它们如何逻辑上生成正确答案。
Question
When was catch me if you can made?
Retrieved document #1: The film due to her busy schedule. The original start date was
January 2002, but was pushed to February 7 in Los Angeles, California. Locations included
Burbank, Downey, New York City, Quebec City and Montreal. …
Retrieved document #2: eventually turned to him for help in catching other check forgers.
Development for the film started in 1980, but did not progress until 1997, when Spielberg's
DreamWorks bought the film rights to Abagnale's book. David Fincher, Gore Verbinski, Lasse
Hallström, Miloš Forman, and Cameron Crowe had all been possible candidates for director
before Spielberg decided to direct. …
Retrieved document #3: It was funded independently and had a budget of $800,000. The film
was Sommers's directorial debut and was written by him. When production finished, the studio
that had promised to distribute the movie had gone out of business, and it was eventually
released by MCA Inc. in July 1989. The movie…
(Other retrieved documents are omitted.)
Raw LLM Answer: 2000 ❌
Standard RAG Answer: 1989 ❌
Self-Reasoning Answer:
(Relevant Aware Process)
Relevant: True
Relevant Reason: The provided documents are relevant with question.
(Evidence Aware Selective Process)
Cite content: [1] … the original start date was January 2002, but was pushed to February 7 in
Los Angeles, …
Reason to cite: This piece provides information on the commencement and location of filming
for 'Catch Me If You Can', indicating that it started in April 2002
Cite content: [3] … When production finished, the studio that had promised to distribute the
movie had gone out of business, and it was eventually released by MCA Inc. in July 1989., …
Reason to cite: This piece provides information on the release date of 'Catch Me If You Can',
indicating that it was eventually released by MCA Inc. in July.
(Trajectory Analysis Process)
Analysis:(long answer)
The film 'Catch Me If You Can' was made in 2002. It started filming in April 2002 in Park Avenue,
just outside the Waldorf-Astoria Hotel, and moved to Orange, New Jersey, before returning to
Brooklyn for bank and courthouse scenes [1].
Final Answer:2002 ✅ (short answer)
https://arxiv.org/pdf/2407.19813Improving Retrieval Augmented Language Model with Self-ReasoningBaidu Inc., China.
53AI,企业落地应用大模型首选服务商
产品:大模型应用平台+智能体定制开发+落地咨询服务
承诺:先做场景POC验证,看到效果再签署服务协议。零风险落地应用大模型,已交付160+中大型企业
2024-11-24
解读GraphRAG
2024-11-24
RAGChecker:显著超越RAGAS,一个精细化评估和诊断 RAG 系统的创新框架
2024-11-23
FastRAG半结构化RAG实现思路及OpenAI O1-long COT蒸馏路线思考
2024-11-23
检索增强生成(RAG):解密AI如何融合记忆与搜索
2024-11-23
如何提高RAG系统准确率?12大常见痛点及巧妙解!
2024-11-23
RAG 2.0性能提升:优化索引与召回机制的策略与实践
2024-11-22
RAG技术在实际应用中的挑战与解决方案
2024-11-22
从普通RAG到RAPTOR,10个最新的RAG框架
2024-07-18
2024-05-05
2024-07-09
2024-05-19
2024-07-09
2024-06-20
2024-07-07
2024-07-07
2024-07-08
2024-07-09
2024-11-06
2024-11-06
2024-11-05
2024-11-04
2024-10-27
2024-10-25
2024-10-21
2024-10-21