arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2411.05345cs.CLcs.AI
收藏

大语言模型对对抗性拼写错误的推理鲁棒性

Reasoning Robustness of LLMs to Adversarial Typographical Errors

National University of Singapore(新加坡国立大学);Singapore University of Technology and Design(新加坡科技设计大学);Google DeepMind(谷歌DeepMind)

Esther Gan, Yiran Zhao, Liying Cheng, Yancan Mao, Anirudh Goyal, Kenji Kawaguchi, Min-Yen Kan, Michael Shieh

AI总结:

本文研究大语言模型对对抗性拼写错误的推理鲁棒性,提出ATA攻击算法和R$^2$ATA基准,证明最小拼写编辑可显著降低模型性能,且攻击具有跨模型迁移性。

摘要:

大语言模型(LLMs)在利用思维链(Chain-of-Thought, CoT)提示进行推理时展现了令人印象深刻的能力。然而,CoT可能受到用户指令的偏见影响。在这项工作中,我们研究了LLMs对拼写错误的推理鲁棒性,这些错误可能自然出现在用户查询中。我们设计了一种对抗性拼写攻击(Adversarial Typo Attack, ATA)算法,该算法迭代地对查询中重要的单词进行拼写错误采样,并选择最有可能成功攻击的编辑。结果表明,LLMs对最小的对抗性拼写变化敏感。值得注意的是,仅1个字符的编辑,Mistral-7B-Instruct在GSM8K上的准确率从43.7%下降到38.6%,而8个字符的编辑则使性能进一步下降到19.2%。为了将评估扩展到更大和闭源的LLMs,我们开发了R$^2$ATA基准,该基准评估模型对ATA的推理鲁棒性。它包含通过将ATA应用于开源LLMs而从三个广泛使用的推理数据集——GSM8K、BBH和MMLU——派生的对抗性拼写问题。R$^2$ATA展示了显著的迁移性,并在多个超大型和闭源LLMs上引起了显著的性能下降。

英文摘要:

Large Language Models (LLMs) have demonstrated impressive capabilities in reasoning using Chain-of-Thought (CoT) prompting. However, CoT can be biased by users' instruction. In this work, we study the reasoning robustness of LLMs to typographical errors, which can naturally occur in users' queries. We design an Adversarial Typo Attack ($\texttt{ATA}$) algorithm that iteratively samples typos for words that are important to the query and selects the edit that is most likely to succeed in attacking. It shows that LLMs are sensitive to minimal adversarial typographical changes. Notably, with 1 character edit, Mistral-7B-Instruct's accuracy drops from 43.7% to 38.6% on GSM8K, while with 8 character edits the performance further drops to 19.2%. To extend our evaluation to larger and closed-source LLMs, we develop the $\texttt{R$^2$ATA}$ benchmark, which assesses models' $\underline{R}$easoning $\underline{R}$obustness to $\underline{\texttt{ATA}}$. It includes adversarial typographical questions derived from three widely used reasoning datasets-GSM8K, BBH, and MMLU-by applying $\texttt{ATA}$ to open-source LLMs. $\texttt{R$^2$ATA}$ demonstrates remarkable transferability and causes notable performance drops across multiple super large and closed-source LLMs.

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

↑