arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2411.00985cs.CL
收藏

FedDTPT:面向黑盒大语言模型的联邦离散可迁移提示调优

FedDTPT: Federated Discrete and Transferable Prompt Tuning for Black-Box Large Language Models

China University of Mining and Technology, Beijing(中国矿业大学(北京));University of British Columbia(不列颠哥伦比亚大学);University of Texas at Dallas(德克萨斯大学达拉斯分校);The Chinese University of Hong Kong, Shenzhen(香港中文大学(深圳))

Jiaqi Wu, Simin Chen, Yuzhe Yang, Yijiang Li, Shiyue Hou, Rui Jing, Zehua Wang, Wei Chen, Zijian Tian

AI总结:

针对大语言模型微调的用户与模型隐私风险及本地部署成本问题,提出面向黑盒LLM的联邦离散可迁移提示调优方法FedDTPT,通过客户端无梯度优化与服务器语义过滤实现高精度、低通信开销且鲁棒的调优效果。

摘要:

近年来,大语言模型(LLMs)极大推动了自然语言处理(NLP)领域的发展。通过使用特定场景的数据对LLMs进行微调,这些基础模型能够更好地适配各类下游任务。然而,微调过程存在隐私泄露风险,在集中式数据处理场景中尤为突出。为解决用户隐私顾虑,学界引入了联邦学习(FL)以降低多源数据集中收集带来的风险。尽管如此,LLMs自身的隐私同样至关重要,潜在的恶意攻击对其安全性构成挑战,而这一问题在当前研究中受到的关注有限。因此,构建可信的多方模型微调环境十分必要。此外,大型LLMs的本地部署会产生高昂的存储成本与极高的计算需求。为应对上述挑战,我们首次提出一种面向黑盒大语言模型的联邦离散可迁移提示调优方法,即FedDTPT。在客户端优化阶段,我们采用token级离散提示优化方法,利用基于预测准确率的反馈循环,通过MLM API驱动无梯度提示优化。在服务器优化阶段,我们使用基于语义相似度的注意力机制过滤所有本地提示token,并结合嵌入距离肘部检测与DBSCAN聚类策略增强过滤效果。实验结果表明,与现有最优方法相比,我们的方法在黑盒设置下实现了更高的准确率、更低的通信开销,且对非独立同分布(non-iid)数据具有鲁棒性。此外,优化后的提示具备可迁移性。

英文摘要:

In recent years, large language models (LLMs) have significantly advanced the field of natural language processing (NLP). By fine-tuning LLMs with data from specific scenarios, these foundation models can better adapt to various downstream tasks. However, the fine-tuning process poses privacy leakage risks, particularly in centralized data processing scenarios. To address user privacy concerns, federated learning (FL) has been introduced to mitigate the risks associated with centralized data collection from multiple sources. Nevertheless, the privacy of LLMs themselves is equally critical, as potential malicious attacks challenge their security, an issue that has received limited attention in current research. Consequently, establishing a trusted multi-party model fine-tuning environment is essential. Additionally, the local deployment of large LLMs incurs significant storage costs and high computational demands. To address these challenges, we propose for the first time a federated discrete and transferable prompt tuning, namely FedDTPT, for black-box large language models. In the client optimization phase, we adopt a token-level discrete prompt optimization method that leverages a feedback loop based on prediction accuracy to drive gradient-free prompt optimization through the MLM API. For server optimization, we employ an attention mechanism based on semantic similarity to filter all local prompt tokens, along with an embedding distance elbow detection and DBSCAN clustering strategy to enhance the filtering process. Experimental results demonstrate that, compared to state-of-the-art methods, our approach achieves higher accuracy, reduced communication overhead, and robustness to non-iid data in a black-box setting. Moreover, the optimized prompts are transferable.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑