Introduction
Sentiment analysis remains a cornerstone of Natural Language Processing (NLP), yet practitioners often grapple with the "paradox of choice" regarding model selection. While numerous studies propose novel architectures for specific benchmarks, there is a lack of rigorous, comparative evaluations across diverse datasets. This study addresses this gap by conducting a systematic comparison of eight deep learning architectures—encompassing both Convolutional Neural Networks (CNNs) and Recurrent Neural Networks (RNNs)—across 13 distinct datasets to determine how model structure, input type, and dataset characteristics influence performance.
Methodology
The researchers benchmarked eight distinct deep learning architectures categorized into two main families:
- CNN-based Models: A shallow 1-layer CNN, a medium 9-layer CNN, and a "very deep" 29-layer CNN.
- RNN-based Models: Vanilla RNN, Long Short-Term Memory (LSTM), Gated Recurrent Unit (GRU), Bidirectional LSTM (BD-LSTM), and Bidirectional GRU (BD-GRU).
Two primary input strategies were evaluated:
- Word-level: Words are mapped to distributed vector representations (embeddings).
- Character-level: Individual characters (letters, digits, punctuation) are treated as unique tokens, enabling the model to learn from sub-word structures.
To ensure experimental fairness, standardized hyperparameters and specific optimizers (Adam for CNNs, RMSProp for RNNs) were applied across all tests.
Experimental Setup
The study utilized 13 review datasets to ensure robust findings across various domains, including 10 Amazon product categories, Amazon Fine Food reviews, TripAdvisor hotel reviews, and the Stanford Sentiment Treebank (SST-Fine). These datasets varied in scale from approximately 9,600 to 568,000 total reviews. Balanced mini-batches were employed during training to mitigate potential class imbalance biases.
Results and Discussion
The comparative analysis yielded several key insights into the performance of deep learning models for sentiment classification:
The Dominance of RNNs at the Word Level
RNN-based models, particularly bidirectional variants, emerged as the superior choice for word-level inputs, outperforming CNNs in 11 out of 13 datasets. The Bidirectional LSTM (BD-LSTM) was the top overall performer, achieving the highest AUROC in 5 datasets. This success is attributed to the RNN's inherent ability to capture long-range sequential dependencies in human language.
The Depth Paradox in CNNs
The relationship between depth and performance in CNNs was found to be highly dependent on the input type. For word-level inputs, the shallow 1-layer CNN consistently outperformed its deeper counterparts (9-layer and 29-layer). In this context, additional layers often introduced noise rather than extracting more useful semantic features.
Conversely, for character-level inputs, depth became a critical requirement. The 29-layer CNN outperformed the 1-layer version in over 60% of the datasets. Since individual characters carry minimal semantic weight, significant depth is necessary to "assemble" these tokens into meaningful features.
Data Volume and Bidirectionality
Regardless of the specific architecture, performance scaled predictably with the volume of training data. Furthermore, adding bidirectionality provided a consistent, though sometimes marginal, performance boost for RNNs compared to the jump from Vanilla RNNs to gated architectures like LSTMs or GRUs.
Conclusion and Future Work
This study highlights that while BD-LSTMs are generally the strongest performers for word-level sentiment analysis, CNNs remain highly competitive, especially when depth is matched to the input granularity (e.g., deep CNNs for character-level data).
Future research should explore the integration of pre-trained or contextualized embeddings (such as BERT), which are likely to further elevate performance. Additionally, expanding the scope to multi-class sentiment classification and investigating the computational efficiency of these models would provide valuable insights for real-world deployment.
Summary updated