HiQA: A Hierarchical Contextual Augmentation RAG for Massive Documents QA

Tips:
本文章只是简单介绍了一下HiQA的三步走流程,对于具体的如果针对表格、图片做相应的处理,还需要深入原论文。
paper link: https://ar5iv.labs.arxiv.org/html/2402.01767
code: https://github.com/TebooNok/HiQA?tab=readme-ov-file

Motivation

The standard RAG struggles to address the massive indistinguishable documents problem.
标准的RAG流程无法解决大量具有相似结构的多文档问答问题。需要加入层级信息。

目标

解决 retrieval problem for multi-documents with similar structures.

核心方法(三步走)

  • Markdown Formatter (MF)
  • Hierarchical Contextual Augmentor (HCA)
  • Multi-Route Retriever (MRR)
    在这里插入图片描述

Markdown Formatter (MF)

The MF module processes the source document, converting it into a markdown file which is a sequence of segments. Rather than dividing the document into fixed-size chunks, each segment corresponds to a natural chapter within the document, comprising both chapter metadata and content. (这一步利用LLM实现) 在这里插入图片描述

Hierarchical Contextual Augmentor (HCA)

HCA module extracts the hierarchical metadata from the markdown and combines it, forming cascading metadata, thereby augmenting the information of each segment.(级联元数据嵌入过程)
在这里插入图片描述

Multi-Route Retriever (MRR).

The MRR module employs a Multi-Route retrieval approach to find the most suitable segments, which are then provided as context inputs to the Language Model.

  • Vector similarity matching
  • Elastic search Elastic(Elasticsearch弥补了基于向量的匹配在单词级精度上的局限性)
  • Keyword matching(关键字匹配则利用了文档语料库中固有的关键词,以解决Elasticsearch的局限性,Elasticsearch主要依赖于统计方法来控制单词权重,所以可能会忽略一些重要的keywors)

这三种方法在检索语义级信息时逐渐减弱,在检索字符级信息时逐渐增强,它们的功能互为补充,因此,我们把它们组合在一起使用:
在这里插入图片描述

  • |C|表示匹配到的关键词的数量
  • α \alpha α: balance the contribution of vector similarity
  • β \beta β: balance the information retrieval scores

更多信息详见here

  • 14
    点赞
  • 9
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值