arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2210.03696cs.CLcs.AIcs.LGcs.SE
收藏

LLMEffiChecker:理解并测试大语言模型的效率退化

LLMEffiChecker: Understanding and Testing Efficiency Degradation of Large Language Models

Taiyuan University of Technology(太原理工大学);The University of Texas at Dallas(德克萨斯大学达拉斯分校)

Xiaoning Feng, Xiaohong Han, Simin Chen, Wei Yang

AI总结:

本文首次系统研究大语言模型的计算效率鲁棒性,提出工具LLMEffiChecker,通过白盒梯度引导与黑盒因果推断生成微小扰动以延迟EOS生成,在九个公开LLMs上使延迟和能耗分别增加325%-3244%和344%-3616%。

摘要:

在本文中,我们首次尝试理解并测试最先进的大语言模型(LLMs)中潜在的计算效率鲁棒性。通过分析20,543个公开可访问的LLMs的工作机制和实现,我们观察到LLMs中一个基本属性,该属性可能被以对抗性方式操纵,从而显著降低计算效率。我们的关键动机是生成能够充分延迟EOS(序列结束标记)生成的测试输入,使得LLMs不得不经历足够的迭代以满足预先配置的阈值。我们提出了工具\ ool,它可以在白盒设置和黑盒设置下工作。在白盒场景中,\ ool开发了一种梯度引导技术,在字符级、词元级和结构级搜索最小且不可察觉的扰动。在黑盒场景中,\ ool采用基于因果推断的方法来找到关键词元,并同样对其应用三个级别的不可感知扰动。白盒和黑盒设置都有效地延迟了EOS的出现,迫使这些输入达到自然无法达到的阈值。为了展示\ ool的有效性,我们对九个公开可用的LLMs进行了系统评估:Google T5、AllenAI WMT14、Helsinki-NLP翻译器、Facebook FairSeq、UNICAMP-DL翻译器、MarianMT、Google FLAN-T5、MBZUAI LaMini-GPT和Salesforce CodeGen。实验结果表明,通过仅扰动输入句子中的一个字符或词元,\ ool平均可以将LLMs的响应延迟和能耗分别增加325%至3244%和344%至3616%。

英文摘要:

In this paper, we make the first attempt to understand and test potential computation efficiency robustness in state-of-the-art LLMs. By analyzing the working mechanism and implementation of 20,543 public-accessible LLMs, we observe a fundamental property in LLMs that could be manipulated in an adversarial manner to reduce computation efficiency significantly. Our key motivation is to generate test inputs that could sufficiently delay the generation of EOS such that LLMs would have to go through enough iterations to satisfy the pre-configured threshold. We present \tool, which can work under both white-box setting and black-box setting. In the white-box scenario, \tool develops a gradient-guided technique that searches for a minimal and unnoticeable perturbation at character-level, token-level, and structure-level. In the black-box scenario, \tool employs a causal inference-based approach to find critical tokens and similarly applies three levels of imperceptible perturbation to them. Both the white-box and black-box settings effectively delay the appearance of EOS, compelling these inputs to reach the naturally-unreachable threshold. To demonstrate the effectiveness of \tool, we conduct a systematic evaluation on nine public-available LLMs: Google T5, AllenAI WMT14, Helsinki-NLP translator, Facebook FairSeq, UNICAMP-DL translator, MarianMT, Google FLAN-T5, MBZUAI LaMini-GPT and Salesforce CodeGen. Experimental results show that \tool can increase on average LLMs' response latency and energy consumption by 325\% to 3244\% and 344\% to 3616\%, respectively, by perturbing just one character or token in the input sentence.

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

↑