《计算机应用》唯一官方网站 ›› 2026, Vol. 46 ›› Issue (3): 696-707.DOI: 10.11772/j.issn.1001-9081.2025030288

• 人工智能 • 上一篇    下一篇

预回答与召回过滤:双阶段RAG问答系统优化方法

黄奕明1, 邹喜华1(), 邓果2, 郑狄1   

  1. 1.西南交通大学 信息科学与技术学院,成都 611756
    2.成都锦西数智科技有限公司,成都 611756
  • 收稿日期:2025-03-24 修回日期:2025-05-15 接受日期:2025-05-19 发布日期:2025-06-03 出版日期:2026-03-10
  • 通讯作者: 邹喜华
  • 作者简介:黄奕明(2000—),男,四川广元人,硕士研究生,主要研究方向:自然语言处理、大语言模型
    邓果(1979—),男,四川泸州人,高级工程师,博士,主要研究方向:人工智能、大语言模型
    郑狄(1982—),男,四川成都人,副教授,博士,主要研究方向:面向光纤传感的人工智能与机器学习、新型光纤传感与检测。
  • 基金资助:
    轨道交通光电融合通信与感知四川省青年科技创新研究团队项目(2022JDTD0013)

Pre-answering and retrieval filtering: dual-stage optimization method for RAG-based question-answering systems

Yiming HUANG1, Xihua ZOU1(), Guo DENG2, Di ZHENG1   

  1. 1.School of Information Science and Technology,Southwest Jiaotong University,Chengdu Sichuan 611756,China
    2.Chengdu Jinxi Technology Company Limited,Chengdu Sichuan 611756,China
  • Received:2025-03-24 Revised:2025-05-15 Accepted:2025-05-19 Online:2025-06-03 Published:2026-03-10
  • Contact: Xihua ZOU
  • About author:HUANG Yiming, born in 2000, M. S. candidate. His research interests include natural language processing, large language models.
    DENG Guo, born in 1979, Ph. D., senior engineer. His research interests include artificial intelligence, large language models.
    ZHENG Di, born in 1982, Ph. D., associate professor. His research interests include artificial intelligence and machine learning for optical fiber sensing, new optical fiber sensing and detection.
  • Supported by:
    Rail Transit Photoelectric Fusion Communication and Perception Project of Sichuan Youth Science and Technology Innovation Research Team(2022JDTD0013)

摘要:

现有的检索增强生成(RAG)问答系统在特定领域应用时,存在检索路径单一、用户潜在意图覆盖不足和召回文段质量低导致的系统回答准确性低与不全面的问题。因此,提出一种双阶段优化方法——预回答与召回过滤(PARF)。首先,通过结合领域知识图谱与提示工程技术,引导大语言模型(LLM)生成预回答,构建“原始查询→预回答→相关文段”的多向检索路径,从而扩展原始查询的语义空间;其次,利用BERT(Bidirectional Encoder Representations from Transformers)模型对召回文段进行相关性评分与过滤,实现检索与生成阶段的协同优化,提升有效信息的密度。实验结果表明,相较于基线方法DPR-LLM(Dense Passage Retrieval with LLM)构建的RAG问答系统,PARF方法构建的RAG问答系统的一致性指标F1和ROUGE-L(Recall-Oriented Understudy for Gisting Evaluation-L)在轨道交通问答数据集上分别提升19.8和41.5个百分点,在医药问答数据集上分别提升16.1和17.6个百分点,效果指标正确率分别提升10.2和8.8个百分点。

关键词: 检索增强生成, 知识图谱, 自然语言处理, 问答系统, 大语言模型, 垂直领域

Abstract:

The existing Retrieval-Augmented Generation (RAG) question-answering systems in domain-specific applications face challenges such as a single retrieval path, insufficient coverage of users’ implicit intents, and low-quality retrieved segments, resulting in inaccurate and incomplete answers. Therefore, a dual-stage optimization method, Pre-Answering and Retrieval Filtering (PARF), was proposed. Firstly, by integrating domain knowledge graphs and prompt engineering techniques, Large Language Models (LLMs) were guided to generate preliminary answers, thereby constructing a multi-directional retrieval path of “original query → preliminary answer → relevant segments” to expand the semantic space of the original query. Secondly, the retrieved segments were scored and filtered based on the relevance using a BERT (Bidirectional Encoder Representations from Transformers) model, thereby enabling collaborative optimization between the retrieval and generation stages, as well as improving the density of effective information. Experimental results show that compared to the RAG question-answering system constructed by the baseline method DPR-LLM (Dense Passage Retrieval with LLM), the RAG question-answering system constructed by PARF method achieves the improvements of 19.8 and 41.5 percentage points in consistency metrics F1 and ROUGE-L (Recall-Oriented Understudy for Gisting Evaluation-L) score, respectively, on a rail transportation question-answering dataset, the improvements of 16.1 and 17.6 percentage points, respectively, on a medical question-answering dataset; and the correct rates of effectiveness metric increased by 10.2 and 8.8 percentage points.

Key words: Retrieval-Augmented Generation (RAG), Knowledge Graph (KG), Natural Language Processing (NLP), question-answering system, Large Language Model (LLM), vertical field

中图分类号: