An Attention-Enhanced Bidirectional Long Short-Term Memory with Contextual Semantic Knowledge for Enhancing Sentiment Analysis

International journal of intelligent engineering and systems · 2025

Sentiment Analysis (SA) is vital to understand emotions and opinions on social media but faces challenges like lexical diversity and dataset imbalance.A hybrid model called Robustly optimized Bidirectional Encoder Representations from Transformers approach and Long Short-Term Memory (RoBERTa-LSTM) framework has been developed to tackle these challenges.However, the LSTM network to learn the most appropriate contextual emotion characteristics, leading to low accuracy, cannot effectively utilize the semantic and emotional data.Hence, this article proposes the RoBERTa and a Contextual Semantic information Embed BiLSTM (CSE-BiLSTM) network model for SA.By integrating BiLSTM instead of LSTM, this model captures both contextual semantic data and long-dependency relationships in the text.At first, the text data is pre-processed and RoBERTa is applied for accurate word embedding.Then, the CSE-BiLSTM model is developed to better integrate external semantic knowledge such as SenticNet into LSTM for SA.It uses contextual semantics, linguistic, and emotional information with BiLSTMs to capture appropriate contextual sentiment characteristics in the review texts.The unified wide exposure emotion lexicon is leveraged to determine the emotion words in the review text for emotion-enriched word embedding.It differentiates words with analogous perspectives but different feelings.An attention strategy is applied to share weights to characteristics and offer more importance to salient characteristics of relevant sentiment context in the texts.Moreover, the softmax is used for classifying the sentiments of the texts.Experiments are conducted using the Twitter US Airline Sentiment dataset, IMDB dataset, and Sentiment140 dataset to validate the model performance.The outcomes show that the RoBERTa-CSE-BiLSTM using the Twitter US Airline Sentiment, IMDB, and Sentiment140 datasets achieves an accuracy of 92.7%, 96%, and 92.5% respectively compared to the BiLSTM, Convolutional Neural Network (CNN)-LSTM, CNN-BiLSTM, BERT-BiLSTM, and XLNet-Gated Recurrent Unit (GRU) network.

Read the paper · More papers on PaperTik