Privacy-Preserving RAG via Multi-Agent Semantic Rewriting: Achieving Confidentiality Without Compromising Contextual Fidelity
作者: Yuanhe Zhao, Tianyu Zhang, Huafei Xing, Derek F. Wong, Jianbin Li, Tao Fang
分类: cs.CL, cs.AI
发布日期: 2026-06-23
备注: This full manuscript contains 23 pages and has been formally accepted for publication in Information Processing & Management (Elsevier IPM). Tao Fang is the corresponding author
🔗 代码/项目: GITHUB
💡 一句话要点
提出多代理语义重写框架以解决隐私保护问题
🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)
关键词: 隐私保护 检索增强生成 多代理系统 语义重写 大型语言模型
📋 核心要点
- 现有的检索增强生成方法在敏感场景中存在隐私泄露的风险,尤其是通过恶意提示进行的攻击。
- 本文提出了一种多代理框架,通过语义重写来清理检索内容,确保隐私保护的同时保留语义信息。
- 实验结果表明,该方法在隐私泄露方面显著降低了目标信息暴露,并在上下文保真度上优于现有方法。
📝 摘要(中文)
检索增强生成(RAG)通过整合外部知识来提升大型语言模型的能力,但在敏感场景中应用时可能面临隐私泄露的风险。为此,本文提出了一种多代理框架,通过语义重写来清理检索内容。该方法利用三个专门代理进行隐私提取、语义分析和重构,协同去除敏感标识符,同时保留语义核心。我们在ChatDoctor和Wiki-PII数据集上对六种大型语言模型进行了评估,实验结果显示在针对性攻击下隐私泄露显著减少。例如,在LLaMA-3-8B模型中,目标信息暴露从基线的144个实例减少到仅1个。此外,我们在上下文保真度方面表现良好,BLEU-1得分为0.122,优于现有SAGE方法的0.117。该框架作为异步预处理模块运行,不会增加在线推理的延迟,所有重写均作为一次性离线预处理步骤执行。为促进可重复性,源代码已公开。
🔬 方法详解
问题定义:本文旨在解决在敏感场景中应用检索增强生成(RAG)时可能出现的隐私泄露问题。现有方法在处理恶意提示时容易暴露敏感信息,亟需改进。
核心思路:提出的多代理框架通过语义重写技术,利用三个专门代理分别进行隐私提取、语义分析和重构,从而有效去除敏感标识符,同时保持语义的完整性。
技术框架:该框架包括三个主要模块:隐私提取代理负责识别和去除敏感信息,语义分析代理确保语义的准确性,重构代理则负责生成最终的清理内容。所有处理均在离线进行,确保在线推理不受影响。
关键创新:最重要的创新在于引入多代理协作机制,能够在不损失语义信息的情况下,有效去除敏感标识符。这一方法与现有的单一处理方法相比,显著提高了隐私保护能力。
关键设计:在设计中,采用了特定的损失函数来平衡隐私保护与语义保真度,同时在网络结构上进行了优化,以提高处理效率和准确性。
🖼️ 关键图片
📊 实验亮点
实验结果显示,在LLaMA-3-8B模型中,目标信息暴露从基线的144个实例减少到仅1个,隐私泄露显著降低。同时,BLEU-1得分为0.122,优于现有SAGE方法的0.117,表明上下文保真度得到了有效保持。
🎯 应用场景
该研究的潜在应用领域包括医疗、金融等需要保护用户隐私的场景。通过有效的隐私保护机制,可以在这些领域中安全地应用大型语言模型,提升用户信任和数据安全性。未来,该方法有望推广到更多需要隐私保护的智能系统中。
📄 摘要(原文)
Retrieval-Augmented Generation enhances large language models by incorporating external knowledge, but deploying it in sensitive scenarios risks privacy leakage via malicious prompts. To address this, we propose a multi-agent framework that sanitizes retrieved content through semantic rewriting. By employing three specialized agents for privacy extraction, semantic analysis, and reconstruction, our approach collaboratively removes sensitive identifiers while preserving the semantic core. We evaluate the framework on the ChatDoctor and Wiki-PII datasets across six large language models. Experimental results demonstrate a significant reduction in privacy leakage under targeted attacks. For instance, we reduced targeted information exposure in LLaMA-3-8B from 144 instances in the baseline to just 1. Furthermore, we maintain strong contextual fidelity with a BLEU-1 score of 0.122, outperforming the existing SAGE method's 0.117. Finally, the framework operates as an asynchronous preprocessing module, introducing no additional latency to online inference, as all rewriting is executed as a one-time offline preprocessing step. To promote reproducibility, the source code of this work is publicly available at https://github.com/foursoils/Privacy-Preserving-RAG.