Journal of Computer Applications

    Next Articles

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

HUANG Yiming1, ZOU Xihua1, DENG Guo2, ZHENG Di1   

  1. 1.School of Information Science and Technology, Southwest Jiaotong University 2.Chengdu Jinxi Technology Company Limited
  • Received:2025-03-20 Revised:2025-05-15 Online:2025-06-03 Published:2025-06-03
  • About author:HUANG Yiming, born in 2000, M. S. candidate. His research interests include natural language processing, large language models. ZOU Xihua, born in 1981, Ph. D., professor. His research interests include artificial intelligence chips and algorithms, intelligent sensing and detection technology. 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, advanced optical fiber sensing and detection technology.
  • Supported by:
    Rail transit photoelectric fusion communication and perception project of Sichuan Youth Science and Technology Innovation research team (2022JDTD0013)

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

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

  1. 1.西南交通大学 信息科学与技术学院 2.成都锦西数智科技有限公司
  • 通讯作者: 邹喜华
  • 作者简介:黄奕明(2000—),男,四川广元人,硕士研究生,主要研究方向:自然语言处理、大语言模型;邹喜华(1981—),男,湖南衡阳人,教授,博士,主要研究方向:人工智能芯片与算法、智能传感与检测技术;邓果(1979—),男,四川泸州人,高级工程师,博士,主要研究方向:人工智能、大语言模型;郑狄(1982—),男,四川成都人,副教授,博士,主要研究方向:面向光纤传感的人工智能与机器学习、新型光纤传感与检测技术。
  • 基金资助:
    轨道交通光电融合通信与感知四川省青年科技创新研究团队(2022JDTD0013)

Abstract: 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. To address these issues, a dual-stage optimization approach, Pre-Answering and Retrieval Filtering (PARF), was proposed. By integrating domain knowledge graphs and prompt engineering techniques, Large Language Models (LLMs) were guided to generate preliminary answers, constructing a multi-directional retrieval path of "original query → preliminary answer → relevant segments" to expand the semantic space of the original query. Subsequently, the retrieved segments were scored and filtered using a Bidirectional Encoder Representations from Transformers (BERT) model to enhance relevance, enabling collaborative optimization between the retrieval and generation stages and improving the density of effective information. Experimental results showed that, compared to the Dense Passage Retrieval with LLM (DPR-LLM) baseline, the RAG question-answering system enhanced by PARF achieved improvements of 19.8 and 41.5 percentage points in F1 and Recall-Oriented Understudy for Gisting Evaluation (ROUGE-L) scores on a rail transportation QA dataset, and 16.1 and 17.6 percentage points on a medical QA dataset. The accuracy of effectiveness metrics increased by 10.2 and 8.8 percentage points, respectively. These findings demonstrate that PARF provides an effective solution for improving the accuracy and comprehensiveness of RAG-based question-answering systems in vertical domains.

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

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

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

CLC Number: