An Empirical Comparison of BERT and Lightweight Variants for IMDb Sentiment Classification
DOI:
https://doi.org/10.61173/kjazw478Keywords:
Sentiment analysis, Transformer-based models, Model compression, IMDb movie reviewsAbstract
Pre-trained transformer models are now the most common choices for sentiment analysis and other text classification tasks. However, their large number of parameters and high inference cost make it hard to deploy them in limited resource settings. To solve this problem, several lightweight variants have been introduced, this paper presents a controlled empirical study of four transformerbased models - BERT-base, DistilBERT, TinyBERT, and ALBERT-base - on the IMDb movie review sentiment classification task. All models are fine-tuned under the same conditions. Besides standard metrics, total and persample inference time were measured as well. To better understand stability, the test set is divided into short and long review subsets based on word count and compare model performance across subsets. Results show an accuracy-efficiency trade-off. BERT-base achieves the highest test accuracy (86.3%), followed by ALBERT (85.7%), while DistilBERT is lower (85.2%) but offers about 2 times faster inference. TinyBERT is the fastest but has lower accuracy (81.3%). Across these models, performance on short reviews is higher than on long reviews. The performance drop from short to long texts is more severe for the smallest model, TinyBERT, finding that highly compressed models struggle more with long and complex texts. This paper discusses the implications of findings for selecting sentiment analysis models under different application requirements.
References
[1] Pang B and Lee L, Opinion Mining and Sentiment Analysis, Foundations and Trends in Information Retrieval, vol. 2, no. 1–2, pp. 1–135, 2008.
[2] Liu B, Sentiment Analysis and Opinion Mining. San Rafael, CA, USA: Morgan & Claypool Publishers, 2012.
[3] Pang B, Lee L, and Vaithyanathan S, Thumbs up? Sentiment classification using machine learning techniques, in Proc. Conf. Empirical Methods in Natural Language Processing (EMNLP), 2002, pp. 79–86.
[4] Devlin J, Chang M W, Lee K, and Toutanova K, BERT: Pre-training of deep bidirectional transformers for language understanding, in Proc. Conf. North American Chapter of the Association for Computational Linguistics: Human Language Technologies (NAACL-HLT), 2019, pp. 4171–4186.
[5] Sanh V, Debut L, Chaumond J, and Wolf T, DistilBERT, a distilled version of BERT: Smaller, faster, cheaper and lighter, arXiv preprint arXiv:1910.01108, 2019.
[6] Jiao X et al., TinyBERT: Distilling BERT for natural language understanding, arXiv preprint arXiv:1909.10351, 2020.
[7] Lan Z et al., ALBERT: A lite BERT for self-supervised learning of language representations, in Proc. Int. Conf. Learning Representations (ICLR), 2020.
[8] Smairi R, Belguith M, & Salah A B. Fine-tune BERT based on machine learning models for sentiment analysis of IMDb movie reviews. Procedia Computer Science, 2024, 246, 2390– 2399.
[9] Gong X, Ying W, Zhong S, and Gong S, Text sentiment analysis based on transformer and augmentation, Frontiers in Psychology, vol. 13, article 906061, 2022.
[10] Zhou P, Zhang Y, and Zhao J, A cross-language attributelevel sentiment analysis approach using TinyBERT and GCN, International Journal of Knowledge Management, vol. 20, no. 1, pp. 1–23, 2024.
[11] Fatihah H A and Ayudhia Z P, TinyBERT-based sentiment analysis for large-scale educational feedback: A case study on Coursera reviews, in Proc. 8th Int. Conf. on Smart Applications, Communications and Networking (SmartNets), 2025.
[12] Gandhi J N and Sharma P, Efficient sentiment classification using DistilBERT for social media data, in Proc. Int. Conf. on Sustainable Innovation in Computing and Engineering (ICSICE-24), 2025.
Downloads
Published
Issue
Section
License
Copyright (c) 2026 by the authors.

This work is licensed under a Creative Commons Attribution 4.0 International License.
