arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2203.12709cs.CL
收藏

对抗训练提高模型鲁棒性?预测与解释

Adversarial Training for Improving Model Robustness? Look at Both Prediction and Interpretation

University of Virginia(弗吉尼亚大学)

Hanjie Chen, Yangfeng Ji

摘要:

神经语言模型显示出对对抗性示例的脆弱性,这些示例在语义上与其原始对应物相似,其中一些单词被其同义词取代。提高模型鲁棒性的一种常见方法是对抗性训练,它遵循两个步骤--通过攻击目标模型来收集对抗性示例,并使用这些对抗性示例在增强数据集上微调模型。传统对抗训练的目标是使模型在原始/对抗样本对上产生相同的正确预测。然而,两个相似文本的模型决策之间的一致性被忽视。我们认为,一个强大的模型应该在原始/对抗样本对上表现一致,也就是说,基于相同的原因(如何)做出相同的预测(什么),这可以通过一致的解释来反映。在这项工作中,我们提出了一种新的特征级对抗训练方法FLAT。FLAT旨在提高模型在预测和解释方面的鲁棒性。FLAT在神经网络中引入了可变的单词掩码,以学习全局单词的重要性,并作为一个瓶颈,教导模型根据重要单词进行预测。FLAT通过正则化相应的全局单词重要性得分,明确地解决了由模型对原始/对抗性示例对中被替换单词及其同义词的理解之间的不匹配引起的脆弱性问题。实验表明,FLAT在提高四种神经网络模型(LSTM,CNN,BERT和DeBERTa)对四种文本分类任务的两种对抗攻击的预测和解释的鲁棒性方面的有效性。通过FLAT训练的模型在不同攻击的不可预见的对抗性示例上也表现出比基线模型更好的鲁棒性。

英文摘要:

Neural language models show vulnerability to adversarial examples which are semantically similar to their original counterparts with a few words replaced by their synonyms. A common way to improve model robustness is adversarial training which follows two steps-collecting adversarial examples by attacking a target model, and fine-tuning the model on the augmented dataset with these adversarial examples. The objective of traditional adversarial training is to make a model produce the same correct predictions on an original/adversarial example pair. However, the consistency between model decision-makings on two similar texts is ignored. We argue that a robust model should behave consistently on original/adversarial example pairs, that is making the same predictions (what) based on the same reasons (how) which can be reflected by consistent interpretations. In this work, we propose a novel feature-level adversarial training method named FLAT. FLAT aims at improving model robustness in terms of both predictions and interpretations. FLAT incorporates variational word masks in neural networks to learn global word importance and play as a bottleneck teaching the model to make predictions based on important words. FLAT explicitly shoots at the vulnerability problem caused by the mismatch between model understandings on the replaced words and their synonyms in original/adversarial example pairs by regularizing the corresponding global word importance scores. Experiments show the effectiveness of FLAT in improving the robustness with respect to both predictions and interpretations of four neural network models (LSTM, CNN, BERT, and DeBERTa) to two adversarial attacks on four text classification tasks. The models trained via FLAT also show better robustness than baseline models on unforeseen adversarial examples across different attacks.

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

↑