arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2109.04380cs.CLcs.AI
收藏

ESimCSE:无监督句子嵌入中对比学习的增强样本构造方法

ESimCSE: Enhanced Sample Building Method for Contrastive Learning of Unsupervised Sentence Embedding

Institute of Information Engineering, Chinese Academy of Sciences(中国科学院信息工程研究所);School of Cyber Security, University of Chinese Academy of Sciences(中国科学院大学网络空间安全学院);Kuaishou Technology(快手科技)

Xing Wu, Chaochen Gao, Liangjun Zang, Jizhong Han, Zhongyuan Wang, Songlin Hu

摘要:

对比学习在无监督句子嵌入的学习中受到了广泛的关注。目前最先进的无监督方法是无监督SimCSE(unsup-SimCSE)。Unsup-SimCSE将dropout作为一种最小的数据增强方法,并将相同的输入语句传递给预先训练好的Transformer编码器(打开dropout)两次,以获得两个相应的嵌入来构建一个正对。由于Transformer中位置嵌入的使用,句子的长度信息通常会被编码到句子嵌入中,因此unsup-SimCSE中的每个正对实际上包含相同的长度信息。因此,用这些正对训练的unsup-SimCSE可能是有偏见的,它倾向于认为相同或相似长度的句子在语义上更相似。通过统计观察,我们发现unsup-SimCSE确实存在这样的问题。为了缓解这种情况,我们应用一个简单的重复操作来修改输入句子,然后将输入句子及其修改后的对应部分分别传递给预先训练好的Transformer编码器,以获得正对。此外,我们从计算机视觉社区中汲取灵感,并引入动量对比,在不进行额外计算的情况下扩大负对的数量。将这两种改进分别应用于正、负两个句子对,构建了一种新的句子嵌入方法--增强型Unsup-SimCSE(ESimCSE)。我们在几个基准数据集上对所提出的ESimCSE进行了语义文本相似性(STS)任务的评估。实验结果表明,ESimCSE优于国家的最先进的unsup-SimCSE的平均斯皮尔曼相关性为2.02%的BERT基础上。

英文摘要:

Contrastive learning has been attracting much attention for learning unsupervised sentence embeddings. The current state-of-the-art unsupervised method is the unsupervised SimCSE (unsup-SimCSE). Unsup-SimCSE takes dropout as a minimal data augmentation method, and passes the same input sentence to a pre-trained Transformer encoder (with dropout turned on) twice to obtain the two corresponding embeddings to build a positive pair. As the length information of a sentence will generally be encoded into the sentence embeddings due to the usage of position embedding in Transformer, each positive pair in unsup-SimCSE actually contains the same length information. And thus unsup-SimCSE trained with these positive pairs is probably biased, which would tend to consider that sentences of the same or similar length are more similar in semantics. Through statistical observations, we find that unsup-SimCSE does have such a problem. To alleviate it, we apply a simple repetition operation to modify the input sentence, and then pass the input sentence and its modified counterpart to the pre-trained Transformer encoder, respectively, to get the positive pair. Additionally, we draw inspiration from the community of computer vision and introduce a momentum contrast, enlarging the number of negative pairs without additional calculations. The proposed two modifications are applied on positive and negative pairs separately, and build a new sentence embedding method, termed Enhanced Unsup-SimCSE (ESimCSE). We evaluate the proposed ESimCSE on several benchmark datasets w.r.t the semantic text similarity (STS) task. Experimental results show that ESimCSE outperforms the state-of-the-art unsup-SimCSE by an average Spearman correlation of 2.02% on BERT-base.

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

↑