计算机科学与探索 ›› 2025, Vol. 19 ›› Issue (5): 1334-1341.DOI: 10.3778/j.issn.1673-9418.2407093

• 人工智能·模式识别 • 上一篇    下一篇

基于多提示学习的方面类别情感分析方法

刘锦行,李琳,吴任伟,刘佳   

  1. 1. 湖北工业大学 计算机学院,武汉 430068
    2. 武汉理工大学 计算机与人工智能学院,武汉 430070
    3. 中国科学院武汉文献情报中心,武汉 430071
    4. 科技大数据湖北省重点实验室,武汉 430071
  • 出版日期:2025-05-01 发布日期:2025-04-28

Multi-prompt Learning Based Aspect-Category Sentiment Analysis

LIU Jinhang, LI Lin, WU Renwei, LIU Jia   

  1. 1. School of Computer Science, Hubei University of Technology, Wuhan 430068, China
    2. School of Computer Science and Artificial Intelligence, Wuhan University of Technology, Wuhan 430070, China
    3. National Science Library (Wuhan) , Chinese Academy of Sciences, Wuhan 430071, China
    4. Hubei Key Laboratory of Big Data in Science and Technology, Wuhan 430071, China
  • Online:2025-05-01 Published:2025-04-28

摘要: 基于方面类别的情感分析(ACSA)旨在辨别评论文本中的方面类别,并同时预测它们的情感极性,是情感分析领域重要的细粒度子任务。近年来,基于预训练语言模型的微调(Fine-tuning)方法已经为方面类别情感分析提供了有效的解决思路。然而,由于预训练任务和下游情感分类任务目标不一致,影响了情感分析质量提升的空间。目前基于提示模板的提示学习(Prompt learning)能够对其进行相应缓解,但人工设计单一的Prompt文本为ACSA任务提供的上下文有限,缺少丰富性。针对此问题,提出了一种基于提示学习的方面类别情感分析方法(Multi-Prompt_ACSA)。在提示学习的基础上进行了提示模板工程和答案工程的多样化设计,结合ACSA的研究特点,提出了适配方面类别情感分析的提示学习方法。引入自回归预训练语言模型进行训练。基于Prompt的多样化设计集成多个不同提示模板下的情感分类结果。与其他模型(非预训练、预训练和提示学习三个类别)在SemEval 2015和SemEval 2016数据集上的结果相比,提出的方法在F1指标上有良好的效果提升。

关键词: 方面类别情感分析, 提示学习, Prompt多样化设计

Abstract: Aspect-category sentiment analysis (ACSA) aims to discern aspect categories in review texts and simultaneously predict their sentiment polarity. It is an important fine-grained subtask in the field of sentiment analysis. Currently, fine-tuning with pretrained language models shows effectiveness in ACSA, but its training tasks are different from downstream ACSA, which limits its analysis quality. Although the prompt template based prompt learning shows its good performance, it is not diverse enough to cover different contexts in the manually designed prompts for ACSA. To solve this problem, this paper proposes an aspect category sentiment analysis method (Multi-Prompt_ACSA) based on prompt learning. Firstly, on the basis of prompt learning, the diversified design of prompt template engineering and answer engineering is carried out. Based on the characteristics of ACSA task, a prompt learning method is proposed to match aspect-category sentiment analysis. Then, an autoregressive pretrained language model is introduced. Further, classification results are integrated based on Prompt??s diverse design. Compared with the results of other models including non-pretrain, pretrain and prompt learning, on the SemEval 2015 and SemEval 2016 datasets, the proposed prompt-based learning method has fine improvement in terms of F1.

Key words: aspect-category sentiment analysis, prompt learning, diversified Prompt design