Skip to main content
QUICK REVIEW

[论文解读] SoftMCL: Soft Momentum Contrastive Learning for Fine-grained Sentiment-aware Pre-training

Jin Wang, Liang-Chih Yu|arXiv (Cornell University)|May 3, 2024
Emotion and Mood Recognition被引用 4
一句话总结

本文提出 SoftMCL,一种用于细粒度情感感知预训练的软动量对比学习框架,使用连续的愉悦度评分作为软标签,而非硬性情感类别。通过结合词级与句级对比学习,并引入动量队列以扩展负样本多样性,SoftMCL 提升了情感表征学习能力,在多个情感分析基准上取得最先进性能,优于现有方法,尤其在捕捉细微情感差异方面表现更优。

ABSTRACT

The pre-training for language models captures general language understanding but fails to distinguish the affective impact of a particular context to a specific word. Recent works have sought to introduce contrastive learning (CL) for sentiment-aware pre-training in acquiring affective information. Nevertheless, these methods present two significant limitations. First, the compatibility of the GPU memory often limits the number of negative samples, hindering the opportunities to learn good representations. In addition, using only a few sentiment polarities as hard labels, e.g., positive, neutral, and negative, to supervise CL will force all representations to converge to a few points, leading to the issue of latent space collapse. This study proposes a soft momentum contrastive learning (SoftMCL) for fine-grained sentiment-aware pre-training. Instead of hard labels, we introduce valence ratings as soft-label supervision for CL to fine-grained measure the sentiment similarities between samples. The proposed SoftMCL is conducted on both the word- and sentence-level to enhance the model's ability to learn affective information. A momentum queue was introduced to expand the contrastive samples, allowing storing and involving more negatives to overcome the limitations of hardware platforms. Extensive experiments were conducted on four different sentiment-related tasks, which demonstrates the effectiveness of the proposed SoftMCL method. The code and data of the proposed SoftMCL is available at: https://www.github.com/wangjin0818/SoftMCL/.

研究动机与目标

  • 为解决预训练语言模型因依赖硬性情感标签而难以捕捉细粒度情感细微差别的局限性。
  • 通过引入动量队列以存储和重用负样本,缓解对比学习中的 GPU 显存限制。
  • 通过将离散情感标签替换为连续愉悦度评分作为监督信号,提升情感表征学习能力。
  • 通过联合词级与句级预训练结合软对比学习,提升模型在情感相关任务上的性能。
  • 证明软标签对比学习在缓解潜在空间坍塌并提升情感泛化能力方面的有效性。

提出的方法

  • SoftMCL 使用连续愉悦度评分作为对比学习的软监督信号,替代硬性情感标签,以实现样本间更精细的相似性度量。
  • 引入动量编码器与动量队列,用于存储和检索历史负样本,将有效负样本池扩展至超出小批量大小的限制。
  • 框架在词级与句级同时进行对比学习,支持多粒度情感表征学习。
  • 训练目标结合掩码语言建模(MLM)与双分支对比损失,其中对比损失通过锚点与正/负样本对之间的温度缩放余弦相似度计算。
  • 动量编码器通过动量系数 μ 更新,使动量网络逐步演化,从而稳定对比学习过程。
  • 通过调优温度 τ、平衡系数 λ₁ 与 λ₂ 以及队列大小等超参数以优化性能,其中 τ=0.1 与队列大小=1024 时表现最佳。
(b) Supervised contrastive learning with hard labels
(b) Supervised contrastive learning with hard labels

实验结果

研究问题

  • RQ1与离散硬标签相比,使用连续愉悦度评分作为软标签是否能提升情感表征学习的质量?
  • RQ2在 GPU 显存受限条件下,使用动量队列是否能显著提升对比学习性能?
  • RQ3与单层次预训练相比,联合词级与句级预训练如何影响情感分类性能?
  • RQ4SoftMCL 框架中超参数(如温度、动量系数与队列大小)的最优配置是什么?
  • RQ5SoftMCL 在情感感知预训练中多大程度上缓解了潜在空间坍塌问题?

主要发现

  • SoftMCL 在四个情感相关基准上取得最先进性能,包括 IMDB 与 MR,最佳结果出现在 λ₁=0.25 与 λ₂=0.25 时。
  • 最优温度超参数 τ=0.1 在 IMDB 与 MR 数据集上均持续取得最佳性能,表明对比学习稳定性与表征质量得到提升。
  • 动量系数 μ=0.9 时性能更优,证明缓慢演化的动量编码器有助于增强表征学习。
  • 队列大小为 1024 时性能最佳,表明更大的队列可提升负样本多样性,且不会引入过多噪声。
  • 消融实验表明,若移除词级或句级预训练,性能均出现一致下降,证实多粒度学习的必要性。
  • 词级预训练的损失在 40,000 步内收敛,句级预训练在 20,000 步内收敛,表明动量队列提供的持久负样本支持了高效学习。
(c) Supervised contrastive learning with soft labels
(c) Supervised contrastive learning with soft labels

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。