arXiv:2506.14084cs.AI2025-06

用小模型提升RAG检索相关性,精度飙升至0.775

Lightweight Relevance Grader in RAG

  • 用12亿参数小模型微调做相关性评分,替代大模型
  • 检索精度从0.1301提升到0.7750,接近700亿参数大模型
  • 适合追求高效部署的RAG系统开发者

检索增强生成(RAG)通过向量数据库补充信息,克服大语言模型的局限。用户提问时,RAG进行向量搜索获取相关文档并生成回答。但确保检索结果与查询的相关性仍是挑战。为此可引入相关性评分模型。本文微调了llama-3.2-1b作为轻量级相关性评分器,使精确率从0.1301大幅提升至0.7750,性能接近llama-3.1-70b。代码已开源。

原文摘要 · Abstract (English)

Retrieval-Augmented Generation (RAG) addresses limitations of large language models (LLMs) by leveraging a vector database to provide more accurate and up-to-date information. When a user submits a query, RAG executes a vector search to find relevant documents, which are then used to generate a response. However, ensuring the relevance of retrieved documents with a query would be a big challenge. To address this, a secondary model, known as a relevant grader, can be served to verify its relevance. To reduce computational requirements of a relevant grader, a lightweight small language model is preferred. In this work, we finetuned llama-3.2-1b as a relevant grader and achieved a significant increase in precision from 0.1301 to 0.7750. Its precision is comparable to that of llama-3.1-70b. Our code is available at https://github.com/taeheej/Lightweight-Relevance-Grader-in-RAG.

RAG小模型相关性评分

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。