Enhancing fine-grained sentiment detection in Chinese text through context-aware attention mechanism and emotional vocabulary fusion
摘要
Fine-grained sentiment detection in Chinese text presents persistent challenges due to the language’s ideographic structure, lack of word delimiters, and rich contextual nuances. Conventional models often fail to fully capture emotional intensity and semantic depth, particularly in complex linguistic environments. To overcome these limitations, this research introduces an architecture, Enhanced Attention Layered Mechanism MemoryNet (EALMM), which integrates context-aware attention mechanisms with emotional vocabulary fusion to enhance fine-grained sentiment detection performance. The proposed model is evaluated using benchmark Chinese sentiment datasets from both user-generated reviews and formal language corpora. The preprocessing pipeline includes word segmentation using stop-word removal, radical decomposition based on Chinese character dictionaries, tokenization, and part-of-speech tagging. Emotional knowledge is encoded through TransE-based embeddings of emotional knowledge triplets, enabling the model to embed structured sentiment information into the feature space. Feature extraction is conducted using Bidirectional Gated Recurrent Units (BiGRU) to capture sequential dependencies. The attention-based bidirectional long short-term memory (BiLSTM) module introduces multi-head layered attention and external memory units that dynamically emphasize emotionally and contextually salient information at multiple semantic levels, including character, word, and phrase granularity. Additionally, radical-level embeddings, emotional part-of-speech features, and multi-scale semantic vectors are combined using a feature-gating fusion mechanism to construct a comprehensive representation. The model is implemented in Python using PyTorch, ensuring modularity and scalability. Experimental results demonstrate that EALMM significantly improves the accuracy of 95.32% and robustness across diverse sentiment analysis tasks in Chinese natural language processing.