PromptRobust: Towards Evaluating the Robustness of Large Language Models on Adversarial Prompts

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Zhu, Kaijie, Wang, Jindong, Zhou, Jiaheng, Wang, Zichen, Chen, Hao, Wang, Yidong, Yang, Linyi, Ye, Wei, Zhang, Yue, Gong, Neil Zhenqiang, Xie, Xing
Format: Preprint
Publié: 2023
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866911956153139200
author Zhu, Kaijie
Wang, Jindong
Zhou, Jiaheng
Wang, Zichen
Chen, Hao
Wang, Yidong
Yang, Linyi
Ye, Wei
Zhang, Yue
Gong, Neil Zhenqiang
Xie, Xing
author_facet Zhu, Kaijie
Wang, Jindong
Zhou, Jiaheng
Wang, Zichen
Chen, Hao
Wang, Yidong
Yang, Linyi
Ye, Wei
Zhang, Yue
Gong, Neil Zhenqiang
Xie, Xing
contents The increasing reliance on Large Language Models (LLMs) across academia and industry necessitates a comprehensive understanding of their robustness to prompts. In response to this vital need, we introduce PromptRobust, a robustness benchmark designed to measure LLMs' resilience to adversarial prompts. This study uses a plethora of adversarial textual attacks targeting prompts across multiple levels: character, word, sentence, and semantic. The adversarial prompts, crafted to mimic plausible user errors like typos or synonyms, aim to evaluate how slight deviations can affect LLM outcomes while maintaining semantic integrity. These prompts are then employed in diverse tasks including sentiment analysis, natural language inference, reading comprehension, machine translation, and math problem-solving. Our study generates 4,788 adversarial prompts, meticulously evaluated over 8 tasks and 13 datasets. Our findings demonstrate that contemporary LLMs are not robust to adversarial prompts. Furthermore, we present a comprehensive analysis to understand the mystery behind prompt robustness and its transferability. We then offer insightful robustness analysis and pragmatic recommendations for prompt composition, beneficial to both researchers and everyday users.
format Preprint
id arxiv_https___arxiv_org_abs_2306_04528
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle PromptRobust: Towards Evaluating the Robustness of Large Language Models on Adversarial Prompts
Zhu, Kaijie
Wang, Jindong
Zhou, Jiaheng
Wang, Zichen
Chen, Hao
Wang, Yidong
Yang, Linyi
Ye, Wei
Zhang, Yue
Gong, Neil Zhenqiang
Xie, Xing
Computation and Language
Cryptography and Security
Machine Learning
The increasing reliance on Large Language Models (LLMs) across academia and industry necessitates a comprehensive understanding of their robustness to prompts. In response to this vital need, we introduce PromptRobust, a robustness benchmark designed to measure LLMs' resilience to adversarial prompts. This study uses a plethora of adversarial textual attacks targeting prompts across multiple levels: character, word, sentence, and semantic. The adversarial prompts, crafted to mimic plausible user errors like typos or synonyms, aim to evaluate how slight deviations can affect LLM outcomes while maintaining semantic integrity. These prompts are then employed in diverse tasks including sentiment analysis, natural language inference, reading comprehension, machine translation, and math problem-solving. Our study generates 4,788 adversarial prompts, meticulously evaluated over 8 tasks and 13 datasets. Our findings demonstrate that contemporary LLMs are not robust to adversarial prompts. Furthermore, we present a comprehensive analysis to understand the mystery behind prompt robustness and its transferability. We then offer insightful robustness analysis and pragmatic recommendations for prompt composition, beneficial to both researchers and everyday users.
title PromptRobust: Towards Evaluating the Robustness of Large Language Models on Adversarial Prompts
topic Computation and Language
Cryptography and Security
Machine Learning
url https://arxiv.org/abs/2306.04528