arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2111.13301cs.CL
收藏

NLP任务的简单对比表示对抗学习

Simple Contrastive Representation Adversarial Learning for NLP Tasks

Beijing Institute of Technology(北京理工大学);Alibaba Group(阿里巴巴集团)

Deshui Miao, Jiaqi Zhang, Wenbo Xie, Jian Song, Xin Li, Lijuan Jia, Ning Guo

摘要:

对比学习等自监督学习方法在自然语言处理中受到广泛关注。该方法利用成对的训练数据扩充,构造出具有良好表示能力的编码器分类任务。然而,在NLP任务中,在对比学习上构建学习对要困难得多。以前的工作产生词级的变化,形成对,但小的转换可能会导致显着的变化,句子的意义作为离散和稀疏的性质自然语言。在本文中,进行对抗训练以在NLP的嵌入空间上生成具有挑战性和更难学习的对抗示例作为学习对。使用对比学习可以提高对抗训练的泛化能力,因为对比损失可以均匀样本分布。同时,对抗性训练也增强了对比学习的鲁棒性。提出了两个新的框架,监督对比对抗学习(SCAL)和无监督SCAL(USCAL),它通过利用对比学习的对抗训练产生学习对。监督任务的基于标签的损失被用来生成对抗性示例,而非监督任务则带来对比损失。为了验证所提出的框架的有效性,我们将其用于基于transformer的模型,用于自然语言理解,句子语义文本相似性和对抗性学习任务。在GLUE基准测试任务上的实验结果表明,我们的微调监督方法优于BERT $_{base}$超过1.75\%。在语义文本相似度(STS)测试中,我们的方法与BERT $_{base}$的测试结果一致,达到了77.29%.我们的方法的鲁棒性在NLI任务的多个对抗数据集下获得了最先进的结果。

英文摘要:

Self-supervised learning approach like contrastive learning is attached great attention in natural language processing. It uses pairs of training data augmentations to build a classification task for an encoder with well representation ability. However, the construction of learning pairs over contrastive learning is much harder in NLP tasks. Previous works generate word-level changes to form pairs, but small transforms may cause notable changes on the meaning of sentences as the discrete and sparse nature of natural language. In this paper, adversarial training is performed to generate challenging and harder learning adversarial examples over the embedding space of NLP as learning pairs. Using contrastive learning improves the generalization ability of adversarial training because contrastive loss can uniform the sample distribution. And at the same time, adversarial training also enhances the robustness of contrastive learning. Two novel frameworks, supervised contrastive adversarial learning (SCAL) and unsupervised SCAL (USCAL), are proposed, which yields learning pairs by utilizing the adversarial training for contrastive learning. The label-based loss of supervised tasks is exploited to generate adversarial examples while unsupervised tasks bring contrastive loss. To validate the effectiveness of the proposed framework, we employ it to Transformer-based models for natural language understanding, sentence semantic textual similarity and adversarial learning tasks. Experimental results on GLUE benchmark tasks show that our fine-tuned supervised method outperforms BERT$_{base}$ over 1.75\%. We also evaluate our unsupervised method on semantic textual similarity (STS) tasks, and our method gets 77.29\% with BERT$_{base}$. The robustness of our approach conducts state-of-the-art results under multiple adversarial datasets on NLI tasks.

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

↑