arXiv:2504.15987cs.CLcs.CY2025-04被引 3

用提示词+对抗增强,让少样本仇恨言论检测更准更快。

Few-shot Hate Speech Detection Based on the MindSpore Framework

  • 引入可学习提示词和注意力池化网络,提升模型泛化能力。
  • 在HateXplain和HSOL数据集上F1分数超越基线模型。
  • 适合资源有限环境下快速部署的仇恨言论检测系统。

社交媒体上仇恨言论的泛滥对在线社区构成严重威胁,亟需有效的检测系统。尽管深度学习模型表现出潜力,但在少样本或低资源场景下,其性能常因依赖大规模标注数据而下降。为此,我们提出基于MindSpore平台的MS-FSLHate框架,采用可学习提示词嵌入、带有注意力池化的CNN-BiLSTM主干网络,并结合同义词对抗数据增强,以提升模型泛化能力。在两个基准数据集HateXplain和HSOL上的实验表明,该方法在精确率、召回率和F1分数上均优于现有基线模型。此外,该框架展现出高效率与良好可扩展性,适用于资源受限环境下的部署。研究结果表明,将提示学习与对抗增强结合,可实现鲁棒且适应性强的少样本仇恨言论检测。

原文摘要 · Abstract (English)

The proliferation of hate speech on social media poses a significant threat to online communities, requiring effective detection systems. While deep learning models have shown promise, their performance often deteriorates in few-shot or low-resource settings due to reliance on large annotated corpora. To address this, we propose MS-FSLHate, a prompt-enhanced neural framework for few-shot hate speech detection implemented on the MindSpore deep learning platform. The model integrates learnable prompt embeddings, a CNN-BiLSTM backbone with attention pooling, and synonym-based adversarial data augmentation to improve generalization. Experimental results on two benchmark datasets-HateXplain and HSOL-demonstrate that our approach outperforms competitive baselines in precision, recall, and F1-score. Additionally, the framework shows high efficiency and scalability, suggesting its suitability for deployment in resource-constrained environments. These findings highlight the potential of combining prompt-based learning with adversarial augmentation for robust and adaptable hate speech detection in few-shot scenarios.

仇恨言论检测少样本学习提示学习MindSpore

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。