Evaluating the Adversarial Robustness of Retrieval-Based In-Context Learning for Large Language Models

要約

LLaMA や OpenAI GPT-3 などの大規模な言語モデルの出現により、インコンテキスト学習 (ICL) はその有効性と効率性により大きな注目を集めました。
ただし、ICL は、プロンプト内のデモンストレーションをエンコードするために使用される選択、順序、および言語化に非常に敏感です。
検索拡張 ICL メソッドは、リトリーバーを利用して意味的に関連する例をデモンストレーションとして抽出することで、この問題に対処しようとします。
このアプローチではより正確な結果が得られますが、テストサンプル、デモンストレーション、取得したデータに対する混乱など、さまざまなタイプの敵対的攻撃に対する堅牢性はまだ調査されていません。
私たちの研究では、検索拡張モデルがテストサンプル攻撃に対する堅牢性を強化し、攻撃成功率 (ASR) が 4.87% 低下してバニラ ICL を上回るパフォーマンスを示していることが明らかになりました。
ただし、彼らはデモンストレーションに対して過信を示しており、デモンストレーション攻撃の ASR が 2% 増加します。
敵対的トレーニングは、敵対的攻撃に対する ICL メソッドの堅牢性を向上させるのに役立ちます。
ただし、LLM のコンテキストでは、このようなトレーニング スキームはコストがかかりすぎる可能性があります。
代替手段として、トレーニング不要の効果的な敵対的防御手法である DARD を導入します。これにより、攻撃されたサンプルのサンプル プールが強化されます。
DARD によってパフォーマンスと堅牢性が向上し、ベースラインと比較して ASR が 15% 削減されることがわかりました。
さらなる研究を促進するためにコードとデータが公開されています: https://github.com/simonucl/adv-retreival-icl

要約(オリジナル)

With the emergence of large language models, such as LLaMA and OpenAI GPT-3, In-Context Learning (ICL) gained significant attention due to its effectiveness and efficiency. However, ICL is very sensitive to the choice, order, and verbaliser used to encode the demonstrations in the prompt. Retrieval-Augmented ICL methods try to address this problem by leveraging retrievers to extract semantically related examples as demonstrations. While this approach yields more accurate results, its robustness against various types of adversarial attacks, including perturbations on test samples, demonstrations, and retrieved data, remains under-explored. Our study reveals that retrieval-augmented models can enhance robustness against test sample attacks, outperforming vanilla ICL with a 4.87% reduction in Attack Success Rate (ASR); however, they exhibit overconfidence in the demonstrations, leading to a 2% increase in ASR for demonstration attacks. Adversarial training can help improve the robustness of ICL methods to adversarial attacks; however, such a training scheme can be too costly in the context of LLMs. As an alternative, we introduce an effective training-free adversarial defence method, DARD, which enriches the example pool with those attacked samples. We show that DARD yields improvements in performance and robustness, achieving a 15% reduction in ASR over the baselines. Code and data are released to encourage further research: https://github.com/simonucl/adv-retreival-icl

arxiv情報

著者 Simon Chi Lok Yu,Jie He,Pasquale Minervini,Jeff Z. Pan
発行日 2024-07-10 11:08:37+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.AI, cs.CL パーマリンク