Sentiment Analysis Using Transformers

Authors

  • Ahmad Fadhil N Faculty of Computing, President University, Jababeka Education Park, Cikarang, Bekasi

Keywords:

Sentiment Analysis, IMDb, BERT, DistilBERT, Transformers

Abstract

This study examines how transformer-based models, such as BERT and DistilBERT, can be used for sentiment analysis of IMDb movie reviews. The goal of the experiment was to find a balance between accuracy and computational efficiency, evaluating how well both models performed with different training parameters. BERT was able to reach a peak accuracy of 91.39% in three epochs, taking a total of 54 minutes to train. On the other hand, DistilBERT achieved a similar accuracy of 91.80% in only 38 minutes and 25 seconds. Although there was a slight variance in accuracy, DistilBERT proved to be a much more efficient option for training, thus becoming a feasible substitute for environments with limited resources. The findings were contrasted against R. Talibzade's (2023) research, which obtained a 98% accuracy rate using BERT but needed 12 hours of training, illustrating the balance between accuracy and training duration. Potential upcoming tasks involve refining further, testing with bigger datasets, investigating alternative transformer models, and utilizing more resource-efficient training methods to improve performance without sacrificing efficiency.

Downloads

Download data is not yet available.

References

T. Ahmed Khan, R. Sadiq, Z. Shahid, M. M. Alam, and M. Mohd Su’ud, “Sentiment Analysis using Support Vector Machine and Random Forest,” J. Informatics Web Eng., 2024, doi: 10.33093/jiwe.2024.3.1.5.

S. K. Singh and N. Singla, “Sentiment Analysis on IMDB Review Dataset,” J. Comput. Mech. Manag., 2023, doi: 10.57159/gadl.jcmm.2.6.230108.

R. Talibzade. “Sentiment Analysis of IMDb Movie Reviews Using Traditional Machine Learning Techniques and Transformers.” 2024. DOI: 10.13140/RG.2.2.29464.16644.

S. Ouyang, “Deep learning for sentiment analysis on IMDB movie reviews using N-gram features,” Appl. Comput. Eng., 2024, doi: 10.54254/2755-2721/35/20230361.

G. Cahyani, W. Widayani, S. D. Anggita, Y. Pristyanto, I. Ikmah, and A. Sidauruk, “Klasifikasi Data Review IMDb Berdasarkan Analisis Sentimen Menggunakan Algoritma Support Vector Machine,” J. MEDIA Inform. BUDIDARMA, 2022, doi: 10.30865/mib.v6i3.4023.

N. G. Ramadhan and T. I. Ramadhan, “Analysis Sentiment Based on IMDB Aspects from Movie Reviews using SVM,” Sinkron, 2022, doi: 10.33395/sinkron.v7i1.11204.

S. M. Qaisar, “Sentiment Analysis of IMDb Movie Reviews Using Long Short-Term Memory,” 2020, doi: 10.1109/ICCIS49240.2020.9257657.

Amulya, K. et al. “Sentiment Analysis on IMDB Movie Reviews Using Machine Learning and Deep Learning Algorithms.” 2022 4th International Conference on Smart Systems and Inventive Technology (ICSSIT). Piscataway: IEEE, 2022. 814–819. Web.

M. R. Haque, S. Akter Lima and S. Z. Mishu, "Performance Analysis of Different Neural Networks for Sentiment Analysis on IMDb Movie Reviews," 2019 3rd International Conference on Electrical, Computer & Telecommunication Engineering (ICECTE), Rajshahi, Bangladesh, 2019, pp. 161-164, doi: 10.1109/ICECTE48615.2019.9303573.

M. Yasen and S. Tedmori, "Movies Reviews Sentiment Analysis and Classification," 2019 IEEE Jordan International Joint Conference on Electrical Engineering and Information Technology (JEEIT), Amman, Jordan, 2019, pp. 860-865, doi: 10.1109/JEEIT.2019.8717422.

IMDB Dataset of 50K Movie Reviews. (n.d.). IMDB Dataset of 50K Movie Reviews | Kaggle. https:///datasets/lakshmi25npathi/imdb-dataset-of-50k-movie reviews

G. Nkhata, "Movie Reviews Sentiment Analysis using BERT." Order No. 29997252, University of Arkansas, United States -- Arkansas, 2022.

Devlin, Jacob & Chang, Ming-Wei & Lee, Kenton & Toutanova, Kristina. (2018). BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding.

T. P. Sahu and S. Ahuja, "Sentiment analysis of movie reviews: A study on feature selection & classification algorithms," 2016 International Conference on Microelectronics, Computing and Communications (MicroCom), Durgapur, India, 2016, pp. 1-6, doi: 10.1109/MicroCom.2016.7522583.

Baid, Palak & Gupta, Apoorva & Chaplot, Neelam. (2017). Sentiment Analysis of Movie Reviews using Machine Learning Techniques. International Journal of Computer Applications. 179. 45-49. 10.5120/ijca2017916005.

Downloads

Published

2024-08-15

How to Cite

Ahmad Fadhil N. (2024). Sentiment Analysis Using Transformers. Jurnal Info Sains : Informatika Dan Sains, 14(03), 410–418. Retrieved from https://ejournal.seaninstitute.or.id/index.php/InfoSains/article/view/5291