Adversarial Text Purification: A Large Language Model Approach for Defense

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Moraffah, Raha, Khandelwal, Shubh, Bhattacharjee, Amrita, Liu, Huan
Format: Preprint
Published: 2024
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866914673564057600
author Moraffah, Raha
Khandelwal, Shubh
Bhattacharjee, Amrita
Liu, Huan
author_facet Moraffah, Raha
Khandelwal, Shubh
Bhattacharjee, Amrita
Liu, Huan
contents Adversarial purification is a defense mechanism for safeguarding classifiers against adversarial attacks without knowing the type of attacks or training of the classifier. These techniques characterize and eliminate adversarial perturbations from the attacked inputs, aiming to restore purified samples that retain similarity to the initially attacked ones and are correctly classified by the classifier. Due to the inherent challenges associated with characterizing noise perturbations for discrete inputs, adversarial text purification has been relatively unexplored. In this paper, we investigate the effectiveness of adversarial purification methods in defending text classifiers. We propose a novel adversarial text purification that harnesses the generative capabilities of Large Language Models (LLMs) to purify adversarial text without the need to explicitly characterize the discrete noise perturbations. We utilize prompt engineering to exploit LLMs for recovering the purified examples for given adversarial examples such that they are semantically similar and correctly classified. Our proposed method demonstrates remarkable performance over various classifiers, improving their accuracy under the attack by over 65% on average.
format Preprint
id arxiv_https___arxiv_org_abs_2402_06655
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Adversarial Text Purification: A Large Language Model Approach for Defense
Moraffah, Raha
Khandelwal, Shubh
Bhattacharjee, Amrita
Liu, Huan
Cryptography and Security
Artificial Intelligence
Computation and Language
Machine Learning
Adversarial purification is a defense mechanism for safeguarding classifiers against adversarial attacks without knowing the type of attacks or training of the classifier. These techniques characterize and eliminate adversarial perturbations from the attacked inputs, aiming to restore purified samples that retain similarity to the initially attacked ones and are correctly classified by the classifier. Due to the inherent challenges associated with characterizing noise perturbations for discrete inputs, adversarial text purification has been relatively unexplored. In this paper, we investigate the effectiveness of adversarial purification methods in defending text classifiers. We propose a novel adversarial text purification that harnesses the generative capabilities of Large Language Models (LLMs) to purify adversarial text without the need to explicitly characterize the discrete noise perturbations. We utilize prompt engineering to exploit LLMs for recovering the purified examples for given adversarial examples such that they are semantically similar and correctly classified. Our proposed method demonstrates remarkable performance over various classifiers, improving their accuracy under the attack by over 65% on average.
title Adversarial Text Purification: A Large Language Model Approach for Defense
topic Cryptography and Security
Artificial Intelligence
Computation and Language
Machine Learning
url https://arxiv.org/abs/2402.06655