Sentiment Analysis Of E-Commerce Reviews Using Fine-Tuned Indobert With Class Weights Strategy

Authors

  • Abdan Syakura Informatics, Faculty of Industrial Technology, Ahmad Dahlan University, Indonesia
  • Dewi Soyusiawaty Informatics, Faculty of Industrial Technology, Ahmad Dahlan University, Indonesia

DOI:

https://doi.org/10.52436/1.jutif.2026.7.3.5654

Keywords:

Deep Learning, IndoBERT, Sentiment Analysis, Tokopedia

Abstract

MSMEs in the e-commerce sector face difficulties in converting large volumes of unstructured customer review data into actionable business insights. This challenge is exacerbated by the ambiguity of star ratings, which often do not align with the content of the reviews, making automated sentiment analysis of the text essential. This study implements a systematic sentiment analysis workflow on a case study of 15,278 customer reviews of Toko Pasar Stan Jogja. The method used is fine-tuning a pre-trained Transformer model, namely IndoBERT, which is optimized with class weighting techniques to handle unbalanced datasets. The model's performance was comprehensively evaluated using Accuracy, Precision, Recall, F1-Score, Confusion Matrix, and word cloud visualization metrics. The test results showed that the developed model had very high performance, achieving an overall accuracy of 96.99% and an average F1-Score of 0.97 on the test data. Qualitative analysis also successfully identified that product quality (“fresh”) and logistics efficiency (‘fast’) were the main drivers of satisfaction, while the main complaints centered on the condition of the product upon arrival (“damaged,” “rotten”). This research proves that the optimized Transformer model is not only effective for sentiment classification, but also serves as a strategic tool for extracting concrete business insights.

Downloads

Download data is not yet available.

References

R. Anadra, H. Wijayanto, and K. Sadik, “Sentiment Analysis of Tokopedia Customer Reviews Using BiLSTM and IndoBERT with Comparative Analysis of Preprocessing and Labeling Methods,” International Journal of Advances in Data and Information Systems, vol. 6, no. 3, pp. 773–788, Dec. 2025, doi: 10.59395/ijadis.v6i3.1458.

Wahyu Widyananda, Maskur, and Ahmad Fauzi, “Machine Learning and Transformer-based Model for Sentiment Analysis of Indonesian E-Commerce Reviews,” The Indonesian Journal of Computer Science, vol. 14, no. 4, Aug. 2025, doi: 10.33022/ijcs.v14i4.4980.

D. Purnamasari, A. B. Aji, S. Madenda, I. M. Wiryana, and S. Harmanto, “SENTIMENT ANALYSIS METHODS FOR CUSTOMER REVIEW OF INDONESIA E-COMMERCE,” International Journal of Innovative Computing, Information and Control, vol. 20, no. 1, pp. 47–60, Feb. 2024, doi: 10.24507/ijicic.20.01.47.

K. Ilmiyah and I. Krishernawan, “Pengaruh Ulasan Produk, Kemudahan, Kepercayaan, Dan Harga Terhadap Keputusan Pembelian Pada Marketplace Shopee Di Mojokerto,” Maker: Jurnal Manajemen, vol. 6, no. 1, pp. 31–42, 2020, doi: 10.37403/mjm.v6i1.143.

C. Raffel et al., “Exploring the limits of transfer learning with a unified text-to-text transformer,” Journal of Machine Learning Research, vol. 21, pp. 1–67, 2020.

H. Jayadianti, W. Kaswidjanti, A. T. Utomo, S. Saifullah, F. A. Dwiyanto, and R. Drezewski, “Sentiment analysis of Indonesian reviews using fine-tuning IndoBERT and R-CNN,” ILKOM Jurnal Ilmiah, vol. 14, no. 3, pp. 348–354, Dec. 2022, doi: 10.33096/ilkom.v14i3.1505.348-354.

M. Naz, H., Ahuja, S., & Kumar, “Recent Trends in Deep Learning Based Sentiment Analysis,” SN Comput. Sci., vol. 4, 2023.

N. Patwardhan, S. Marrone, and C. Sansone, “Transformers in the Real World: A Survey on NLP Applications,” Information (Switzerland), vol. 14, no. 4, 2023, doi: 10.3390/info14040242.

Wahyu Widyananda, Maskur, and Ahmad Fauzi, “Machine Learning and Transformer-based Model for Sentiment Analysis of Indonesian E-Commerce Reviews,” The Indonesian Journal of Computer Science, vol. 14, no. 4, Aug. 2025, doi: 10.33022/ijcs.v14i4.4980.

and P. I. D. A. Indrawati, L. Ilmu, P. Indonesia, “Penerapan Teknik Kombinasi Oversampling Dan Undersampling Hybrid Oversampling and Undersampling Techniques To Handling Imbalanced Dataset,” vol. 4, no, no. doi: 10.33387/jiko., pp. 38–43, 2021.

B. BAKIRARAR and A. H. ELHAN, “Class Weighting Technique to Deal with Imbalanced Class Problem in Machine Learning: Methodological Research,” Turkiye Klinikleri Journal of Biostatistics, vol. 15, no. 1, pp. 19–29, 2023, doi: 10.5336/biostatic.2022-93961.

S. A. Ihalauw, N. Trezandy Lapatta, D. Wiria Nugraha, Wirdayanti, and C. Ar Lamasitudju, “Analisis Sentimen Terhadap Kinerja Awal Pemerintahan Menggunakan IndoBERT Dan SMOTE Pada Media Sosial X,” Jurnal Algoritma, vol. 22, no. 2, Nov. 2025, doi: 10.33364/algoritma/v.22-2.2957.

A. Anas Qolbu and N. Fitriyati, “Performa Naïve Bayes, SVM, dan IndoBERT pada Analisis Sentimen Twitter IndiHome dengan Strategi Penanganan Data Tidak Seimbang,” vol. 814, no. 1, pp. 29–44, 2025, doi: 10.14421/fourier.2025.141.29-44.

B. Setiawan, “A Review of Sentiment Analysis Applications in Indonesia Between 2023-2024.”

R. N. R. Suripto, “Teknik pre-processing dan classification dalam data science.,” Mie.Binus.Ac.Id.

M. Nabil et al., “Jurnal Teknologi dan Manajemen Informatika Sentiment Analysis of NTB Syariah Bank Application Services using The Naïve Bayes and Support Vector Machine Methods Article Info ABSTRACT,” vol. 11, no. 2, pp. 177–188, 2025, [Online]. Available: http://http://jurnal.unmer.ac.id/index.php/jtmi

H. Babaei, M. Zamani, and S. Mohammadi, “The impact of data splitting methods on machine learning models: A case study for predicting concrete workability,” Machine Learning for Computational Science and Engineering, vol. 1, no. 1, p. 21, 2025, doi: 10.1007/s44379-025-00021-3.

and J. G. A. Gupta, N. Tatbul, R. Marcus, S. Zhou, I. Lee, “CLASS-WEIGHTED EVALUATION METRICS FOR IMBALANCED DATA CLASSIFICATION,” vol. 55, no. 1, pp. 1–14, 2020.

V. Chandradev, I. M. A. D. Suarjana, and I. P. A. Bayupati, “Chandradev, Analisis Sentimen Review Hotel menggunakan Metode Deep Learning BERT 107 Analisis Sentimen Review Hotel Menggunakan Metode Deep Learning BERT,” Jurnal Buana Informatika, vol. 14, pp. 107–115, 2023.

Maulidya Prastita Syah, Ajeng Puspa Wardani, Mohammad Idhom, and Trimono, “Perbandingan Representasi Teks Tf-Idf Dan Bert Terhadap Akurasi Cosine Similarity Dalam Penilaian Otomatis Jawaban Berbasis Teks,” Data Sciences Indonesia (DSI), vol. 5, no. 1, pp. 47–59, 2025, doi: 10.47709/dsi.v5i1.6021.

Y. Liu, J. Yu, Y. Xu, Z. Li, and Q. Zhu, “A Survey on Transformer Context Extension: Approaches and Evaluation,” 2025, [Online]. Available: https://arxiv.org/abs/2503.13299v1

M. Galih Pradana, “Penggunaan Fitur Wordcloud Dan Document Term Matrix Dalam Text Mining,” Jurnal Ilmiah Infromatika (JIF), vol. 08, no. 01, pp. 38–43, 2020.

R. Merdiansah, S. Siska, and A. Ali Ridha, “Analisis Sentimen Pengguna X Indonesia Terkait Kendaraan Listrik Menggunakan IndoBERT,” Jurnal Ilmu Komputer dan Sistem Informasi (JIKOMSI), vol. 7, no. 1, pp. 221–228, 2024, doi: 10.55338/jikomsi.v7i1.2895.

G. T. Fadilah, L. Muflikhah, and R. S. Perdana, “Analisis Sentimen Produk Hijab Pada E-Commerce Tokopedia Menggunakan Algoritma Support Vector Machine Dan Indobert Embedding,” Jurnal Pengembangan Teknologi Informasi dan Ilmu Komputer, vol. 9, no. 2, pp. 1–9, 2025, [Online]. Available: http://j-ptiik.ub.ac.id

M. Mujahid et al., “Data oversampling and imbalanced datasets: an investigation of performance for machine learning and feature engineering,” J. Big Data, vol. 11, no. 1, Dec. 2024, doi: 10.1186/s40537-024-00943-4.

Additional Files

Published

2026-06-15

How to Cite

[1]
A. . Syakura and D. . Soyusiawaty, “Sentiment Analysis Of E-Commerce Reviews Using Fine-Tuned Indobert With Class Weights Strategy”, J. Tek. Inform. (JUTIF), vol. 7, no. 3, pp. 2690–2703, Jun. 2026.