Adversarial Robustness of Prompt-based Few-Shot Learning for Natural Language Understanding

Venkata Prabhakara Sarath Nookala, Gaurav Verma, Subhabrata Mukherjee, Srijan Kumar
6/19/2023
cs.CLcs.LG

Official code: claws-lab/few-shot-adversarial-robustness (5 stars, MIT, last commit 2024-03-03).

Abstract

State-of-the-art few-shot learning (FSL) methods leverage prompt-based fine-tuning to obtain remarkable results for natural language understanding (NLU) tasks. While much of the prior FSL methods focus on improving downstream task performance, there is a limited understanding of the adversarial robustness of such methods. In this work, we conduct an extensive study of several state-of-the-art FSL methods to assess their robustness to adversarial perturbations. To better understand the impact of various factors towards robustness (or the lack of it), we evaluate prompt-based FSL methods against fully fine-tuned models for aspects such as the use of unlabeled data, multiple prompts, number of few-shot examples, model size and type. Our results on six GLUE tasks indicate that compared to fully fine-tuned models, vanilla FSL methods lead to a notable relative drop in task performance (i.e., are less robust) in the face of adversarial perturbations. However, using (i) unlabeled data for prompt-based FSL and (ii) multiple prompts flip the trend. We further demonstrate that increasing the number of few-shot examples and model size lead to increased adversarial robustness of vanilla FSL methods. Broadly, our work sheds light on the adversarial robustness evaluation of prompt-based FSL methods for NLU tasks.

View on arXivView PDF

Code Implementations(1)

MIT

Code for ACL'23 Findings paper on 'Adversarial Robustness of Prompt-based Few-Shot Learning for Natural Language Understanding'

51Shell, PythonMay 24, 20232 years agoMIT

Similar Papers

Cite this paper

@article{nookala2023adversarial,
  title  = {Adversarial Robustness of Prompt-based Few-Shot Learning for Natural Language Understanding},
  author = {Venkata Prabhakara Sarath Nookala and Gaurav Verma and Subhabrata Mukherjee and Srijan Kumar},
  year   = {2023},
  eprint = {2306.11066},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2306.11066v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2306.11066.svg)](https://codeofpaper.com/paper/2306.11066)

Discussion