An Extensive Evaluation of Machine Learning and Deep Learning Approaches for Sentiment Analysis: Insights from Amazon Customer Reviews

Muhammed Ihsan Corak, Cuiyuan Wang, Xiaowen Zhang
11/12/2026
cs.LG

No confident code implementation found for this paper.

Abstract

The rapid growth of user-generated text on online platforms creates opportunities for understanding customer opinion and supporting data-driven decisions. This study compares five traditional machine learning classifiers (Random Forest, Logistic Regression, Bernoulli Naive Bayes, Linear Support Vector Classifier, and Multinomial Naive Bayes) and six deep learning architectures (LSTM, Bi-LSTM, GRU, RNN, Attention, and FastText) for three-class sentiment classification of 568,454 Amazon Fine Food Reviews.

Show full abstract

Machine learning models used Bag-of-Words (BoW) and TF-IDF features limited to 5,000 terms; deep learning models used learned embeddings over a 20,000-word vocabulary. Models were evaluated on the original imbalanced data and on a random-oversampled balanced set of 1,070,469 reviews, using accuracy, macro and per-class precision, recall, and F1-score, and training time. On the balanced set, Random Forest with BoW achieved 99\% accuracy and the Attention model achieved 98.7\%. Linear SVC reached 89\% accuracy in 1 min 15 s, and Logistic Regression reached 90\% in 3 min 37 s. On the imbalanced set, the Attention model achieved 97.8\% accuracy, and FastText achieved 95.3\% in 3 min 26 s, while the RNN reached 91.9\% with a neutral-class F1-score of 0.08. Deep learning models were more stable across class distributions, whereas the best classical model depended on balancing. We also report a user-facing application that applies the trained Random Forest and Attention models to new review text. Because the labels are derived from star ratings, the results measure agreement with rating-derived sentiment classes rather than annotated sentiment; the dataset is a single source, and the findings should be read with that limitation in mind.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{corak2026extensive,
  title  = {An Extensive Evaluation of Machine Learning and Deep Learning Approaches for Sentiment Analysis: Insights from Amazon Customer Reviews},
  author = {Muhammed Ihsan Corak and Cuiyuan Wang and Xiaowen Zhang},
  year   = {2026},
  eprint = {2611.16201},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2611.16201v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2611.16201.svg)](https://codeofpaper.com/paper/2611.16201)

Discussion