This is an unedited manuscript accepted for publication and provided as an Article in Press for early access at the author’s request. The article will undergo copyediting, typesetting, and galley proof review before final publication. Please be aware that errors may be identified during production that could affect the content. All legal disclaimers of the journal apply.
Mintu Nagar,
Chetan Kumar,
Shalini Puri,
- Research Scholar, Department of Computer Science and Engineering, Kautilya Institute of Technology and Engineering, Jaipur, Rajasthan, India
- Associate Professor, Department of Computer Science and Engineering, Kautilya Institute of Technology and Engineering, Jaipur, Rajasthan, India
- Associate Professor, Department of Information Technology, Manipal University, Jaipur, Rajasthan, India
Abstract
In the increased digitalization, the sentiment analysis and classification have evolved as an eminent area to determine the polarity of positive, negative, and neutral reviews of the customers and users on products. It is an integral application field that employs supervised learning, Machine Learning, and Natural Language Processing concepts. The proposed Semantic Analysis and Classification using Naive Bayes and Random Forest system accomplishes the sentiment polarity by classifying the user reviews into three categories. It extracted the features from the structured form of Amazon reviews and then employed the training and testing stages through Naive Bayes and Random Forest techniques. Several experiments were performed on the datasets of several products from an online shopping website, Amazon. The review dataset for the proposed system was collected from eight popular categories: mobile phones, scientific supplies, musical instruments, cameras, televisions, books, kitchen items, and grocery items. This system was tested on approximately 26,000 reviews. The highest number of positive and negative reviews were obtained for the “Mobile Phones” and “Cameras” categories. The best ratings of 4.5 and 4.3 were achieved using Naive Bayes and Random Forest classifiers for Amazon products, respectively. The system’s predicted ratings differed only slightly from the actual ratings on Amazon, with the maximum differences being –0.20 for “Scientific Supplies” and +0.25 for “Kitchen Items”. The proposed system obtained 97% precision, 92% recall, and 95% F1-score using the Naive Bayes classifier. It obtained 96% precision, 91% recall, and 93.75% F1-score using the random forest classifier. The overall 94.1% system accuracy was achieved, using the Naive Bayes classifier.
Keywords: Online products, sentiment analysis, classification, Random Forest, Naive Bayes, Amazon, reviews
[This article belongs to Journal of Artificial Intelligence Research & Advances ]
Mintu Nagar, Chetan Kumar, Shalini Puri. Optimizing Sentiment Analysis with Naïve Bayes and Random Forest Techniques: A Result-based Approach. Journal of Artificial Intelligence Research & Advances. 2025; 12(02):-.
Mintu Nagar, Chetan Kumar, Shalini Puri. Optimizing Sentiment Analysis with Naïve Bayes and Random Forest Techniques: A Result-based Approach. Journal of Artificial Intelligence Research & Advances. 2025; 12(02):-. Available from: https://journals.stmjournals.com/joaira/article=2025/view=0
References
- Puri S, Kaushik S. An enhanced fuzzy similarity based concept mining model for text classification using feature clustering. In 2012 IEEE Students Conference on Engineering and Systems. 2012 Mar 16; 1–6.
- Dey UK, Noor A. Comparative Exploration of Prediction Algorithms for Sentiment Analysis Using NLP. In 2019 International Conference on Computer Communication and Informatics (ICCCI). 2019 Jan 23; 1–6.
- Alrehili A, Albalawi K. Sentiment analysis of customer reviews using ensemble method. In 2019 IEEE International conference on computer and information sciences (ICCIS). 2019 Apr 3; 1–6.
- Shaheen M, Awan SM, Hussain N, Gondal ZA. Sentiment analysis on mobile phone reviews using supervised learning techniques. Int J Mod Educ Comput Sci. 2019 Jul 1; 10(7): 32–43.
- Rintyarna BS, Sarno R, Fatichah C. Evaluating the performance of sentence level features and domain sensitive features of product reviews on supervised sentiment analysis tasks. J Big Data. 2019 Dec; 6: 1–9.
- Jadhav HB, Jadhav AB. Systematic approach towards sentiment analysis in online review’s. In Proceeding of the International Conference on Computer Networks, Big Data and IoT (ICCBI- 2018). Cham: Springer International Publishing; 2020; 358–369.
- Kunaefi A, Aritsugi M. Characterizing user decision based on argumentative reviews. In 2020 IEEE/ACM International Conference on Big Data Computing, Applications and Technologies (BDCAT). 2020 Dec 7; 161–170.
- Khan S, Chopra K, Sharma P. Brand review prediction using user sentiments: Machine learning algorithm. In 2nd IEEE International Conference on Data, Engineering and Applications (IDEA) 2020 Feb 28; 1–8.
- Khan A, Younis U, Kundi AS, Asghar MZ, Ullah I, Aslam N, Ahmed I. Sentiment classification of user reviews using supervised learning techniques with comparative opinion mining perspective. In Advances in Computer Vision: Proceedings of the 2019 Computer Vision Conference (CVC). Vol. 2. Cham: Springer International Publishing; 2020; 23–29.
- Elfaik H, Nfaoui EH. A comparative evaluation of classification algorithms for sentiment analysis using word embeddings. In Advanced Intelligent Systems for Sustainable Development (AI2SD’2019). Vol. 4: Advanced Intelligent Systems for Applied Computing Sciences. Cham: Springer International Publishing; 2020; 1–11.
- Mandhula T, Pabboju S, Gugulotu N. Predicting the customer’s opinion on amazon products using selective memory architecture-based convolutional neural network. J Supercomput. 2020 Aug; 76(8): 5923–47.
- Mahadevan A, Arock M. Review rating prediction using combined latent topics and associated sentiments: an empirical review. Serv Oriented Comput Appl. 2020 Mar; 14(1): 19–34.
- Wang B, Wang R, Liu S, Chai Y, Xing S. Aspect-level sentiment analysis of online product reviews based on multi-features. InSemantic Technology: 9th Joint International Conference, JIST 2019, Hangzhou, China, November 25–27, 2019, Revised Selected Papers 9. Singapore: Springer; 2020; 161–169.
- Srikanth K, Murthy NV, Prasad Reddy PV. Sentiment classification on online retailer reviews. In ICCCE 2020: Proceedings of the 3rd International Conference on Communications and Cyber Physical Engineering. Singapore: Springer Nature Singapore; 2020 Oct 12; 1557–1563.
- Sindhu C, Rajkakati D, Shelukar C. Context-based sentiment analysis on amazon product customer feedback data. In Artificial Intelligence Techniques for Advanced Computing Applications: Proceedings of ICACT 2020. Singapore: Springer Singapore; 2020 Jul 24; 515–527.
- Chauhan G, Puri S, Nahta R. Analysis of Government Flagship Programs using Public Feedbacks. In 2023 IEEE 2nd International Conference for Innovation in Technology (INOCON). 2023 Mar 3; 1–7.
- Meena P, Kumar C, Puri S. Customer segmentation and behavioral systems through influential effective elements: An E-satisfaction analysis using machine learning. In AIP Conf Proc. 2023 Jun 15; 2782(1). AIP Publishing.
- Ahamad R, Mishra KN. Exploring sentiment analysis in handwritten and E-text documents using advanced machine learning techniques: a novel approach. J Big Data. 2025 Jan 23; 12(1): 11.

Journal of Artificial Intelligence Research & Advances
| Volume | 12 |
| Issue | 02 |
| Received | 05/03/2025 |
| Accepted | 21/03/2025 |
| Published | 19/04/2025 |
| Publication Time | 45 Days |
[first_name] [last_name]