Jisuanji kexue yu tansuo (Apr 2020)
Using Position-Enhanced Attention Mechanism for Aspect-Based Sentiment Classi-fication
Abstract
Aspect-based sentiment classification is designed to accurately identify the emotional polarity of aspect in a comment. Most existing long short term memory (LSTM) network uses only the semantic information of aspects and contexts, while ignoring the function of relative position information between the aspect and the context. To solve this problem, this paper proposes an LSTM-based model that uses relative position information to enhance attention and solves the aspect-based sentiment classification problem. First, the position vector is added to the input layer of the context, and the context and the aspect are separately encoded by using two LSTM networks. Then, the position vector is stitched again to the hidden layer of the context, and the hidden layer vector of the aspect is used to calculate the attention weight of different words in the context. Finally, sentiment classification is performed using a valid representation generated by the context. The model is tested on the Restaurant and Laptop datasets of SemEval 2014 Task4. In the three-category experiments, the accuracies of the proposed model are 79.7% and 72.1% respectively. In the two-category experiments, the accuracies reach 92.1% and 88.3% respectively. The proposed model has a certain improvement in accuracy compared to multiple baseline models.
Keywords