Optimasi RoBERTa dengan Hyperparameter Tuning untuk Deteksi Emosi berbasis Teks

Penulis

  • Elvanro Marthen Pusung Program Studi Sistem Informasi, Fakultas Ilmu Komputer, Universitas Dian Nuswantoro
  • Ika Novita Dewi Program Studi Sistem Informasi, Fakultas Ilmu Komputer, Universitas Dian Nuswantoro https://orcid.org/0009-0001-5551-379X

DOI:

https://doi.org/10.25077/TEKNOSI.v10i3.2024.226-233

Kata Kunci:

Deteksi Emosi, RoBERTa, Hyperparameter Tuning, Teks Bahasa Indonesia, Natural Language Processing

Abstrak

Deteksi emosi berbasis teks menjadi salah satu topik utama pembahasan dalam pemrosesan bahasa alami. Hal ini dapat disebabkan karena adanya peningkatan jumlah data yang dihasilkan dari interaksi digital, seperti media sosial dan aplikasi pesan instan. Deteksi emosi bertujuan untuk mengenali dan menganalisis respons emosional individu dalam situasi tertentu, dengan penerapan di berbagai bidang seperti interaksi manusia dengan komputer, analisis sentimen, dan layanan kesehatan mental. Penelitian ini bertujuan untuk meningkatkan performa deteksi emosi berbasis teks Bahasa Indonesia menggunakan model RoBERTa. RoBERTa merupakan salah satu varian dari model BERT (Bidirectional Encoder Representations from Transformers) yang telah dioptimalkan untuk pemrosesan bahasa alami dengan mempertimbangkan konteks linguistik secara lebih mendalam. Implementasi RoBERTa dalam deteksi emosi akan dioptimalkan melalui hyperparameter tuning seperti Grid Search, Randomized Search, dan Bayesian Optimization untuk memperoleh kombinasi nilai learning rate, batch size, dan epoch yang optimal, dengan tujuan meningkatkan akurasi dan kemampuan model dalam mendeteksi emosi secara konsisten. Deteksi emosi menggunakana dataset yang terdiri dari 7080 data tweet publik dengan enam kategori emosi, yaitu anger, fear, joy, love, sad, dan neutral. Hasil eksperimen menunjukkan bahwa metode Bayesian Optimization memberikan kombinasi hyperparameter yang optimal dan meningkatkan performa deteksi emosi pada teks berbahasa Indonesia dengan hasil akurasi sebesar  83,64% dan nilai precision, recall dan F1-score secara berutur-turut adalah 83,75%, 83,64%, dan 83,58%.

Referensi

W. Anggriyani and M. Fakhriza, “Analisis Sentimen Program Makan Gratis Pada Media Sosial X Menggunakan Metode NLP,†Journal of Computer System and Informatics (JoSYC), vol. 5, no. 4, pp. 1033–1042, 2024, doi: 10.47065/josyc.v5i4.5826.

T. I. Z. M. Putra, S. Suprapto, and A. F. Bukhori, “Model Klasifikasi Berbasis Multiclass Classification dengan Kombinasi Indobert Embedding dan Long Short-Term Memory untuk Tweet Berbahasa Indonesia,†Jurnal Ilmu Siber dan Teknologi Digital, vol. 1, no. 1, pp. 1–28, Nov. 2022, doi: 10.35912/jisted.v1i1.1509.

A. Hamzah and R. Yanwastika Ariyana, “Klasifikasi Emosi Berbasis Emolex dari Komentar Evaluasi Akademik Mahasiswa Emolex-Based Classification of Emotions from Academic Evaluation Comments,†Techno.COM, vol. 23, no. 2, pp. 457–468, May 2024, doi: https://doi.org/10.62411/tc.v23i2.10058.

S. Imron, E. I. Setiawan, and J. Santoso, “Deteksi Aspek Review E-Commerce Menggunakan IndoBERT Embedding dan CNN,†Journal of Intelligent System and Computation, vol. 5, no. 1, pp. 10–16, Apr. 2023, doi: 10.52985/insyst.v5i1.267.

E. Y. Hidayat and D. Handayani, “Penerapan 1D-CNN untuk Analisis Sentimen Ulasan Produk Kosmetik Berdasar Female Daily Review,†Jurnal Nasional Teknologi dan Sistem Informasi, vol. 8, no. 3, pp. 153–163, Jan. 2023, doi: 10.25077/teknosi.v8i3.2022.153-163.

E. Y. Hidayat, R. W. Hardiansyah, and A. Affandy, “Analisis Sentimen Twitter untuk Menilai Opini Terhadap Perusahaan Publik Menggunakan Algoritma Deep Neural Network,†Jurnal Nasional Teknologi dan Sistem Informasi, vol. 7, no. 2, pp. 108–118, Sep. 2021, doi: 10.25077/teknosi.v7i2.2021.108-118.

A. Ansori, “Kepribadian dan Emosi,†Jurnal Literasi Pendidikan Nusantara, vol. 1, no. 1, pp. 41–54, Jun. 2020.

Y. K. Wiciaputra, J. C. Young, and A. Rusli, “Bilingual text classification in english and indonesian via transfer learning using XLM-RoBERTa,†International Journal of Advances in Soft Computing and its Applications, vol. 13, no. 3, pp. 72–87, 2021, doi: 10.15849/ijasca.211128.06.

B. Richardson and A. Wicaksana, “Comparison Of Indobert-Lite And Roberta In Text Mining For Indonesian Language Question Answering Application,†International Journal of Innovative Computing, Information and Control, vol. 18, no. 6, pp. 1719–1734, Dec. 2022, doi: 10.24507/ijicic.18.06.1719.

M. Evtimova, “Hyperparameter Tuning for Address Validation using Optuna,†WSEAS. Transactions on Computer Research, vol. 12, pp. 105–111, Nov. 2023, doi: 10.37394/232018.2024.12.10.

R. Khusuma, W. Maharani, and P. H. Gani, “Personality Detection On Twitter User With RoBERTa,†Jurnal Media Informatika Budidarma, vol. 7, no. 1, p. 542, Feb. 2023, doi: 10.30865/mib.v7i1.5598.

S. Akrah, “DuluthNLP at SemEval-2021 Task 7: Fine-Tuning RoBERTa Model for Humor Detection and Offense Rating,†in Proceedings of the 15th International Workshop on Semantic Evaluation (SemEval-2021), Aug. 2021, pp. 1196–1203.

A. C. N. Simanjuntak et al., “Studi dan Analisis Hyperparameter Tuning IndoBERT Dalam Pendeteksian Berita Palsu,†Jurnal Nasional Teknik Elektro Dan Teknologi Informasi, vol. 13, no. 1, pp. 60–67, 2024, doi: 10.22146/jnteti.v13i1.8532.

D. A. Anggoro and S. S. Mukti, “Performance Comparison of Grid Search and Random Search Methods for Hyperparameter Tuning in Extreme Gradient Boosting Algorithm to Predict Chronic Kidney Failure,†International Journal of Intelligent Engineering and Systems, vol. 14, no. 6, pp. 198–207, Dec. 2021, doi: 10.22266/ijies2021.1231.19.

I. S. Kervanci, M. F. Akay, and E. Özceylan, “Bitcoin Price Prediction Using Lstm, Gru And Hybrid Lstm-Gru With Bayesian Optimization, Random Search, And Grid Search For The Next Days,†Journal of Industrial and Management Optimization, vol. 20, no. 2, pp. 570–588, Feb. 2024, doi: 10.3934/jimo.2023091.

S. Prabu, B. Thiyaneswaran, M. Sujatha, C. Nalini, and S. Rajkumar, “Grid Search for Predicting Coronary Heart Disease by Tuning Hyper-Parameters,†Computer Systems Science and Engineering, vol. 43, no. 2, pp. 737–749, 2022, doi: 10.32604/csse.2022.022739.

Riccosan, K. E. Saputra, G. D. Pratama, and A. Chowanda, “Emotion dataset from Indonesian public opinion,†Data Brief, vol. 43, no. 108465, pp. 1–6, Jul. 2022.

V. Çetin and O. Yıldız, “A comprehensive review on data preprocessing techniques in data analysis,†Pamukkale University Journal of Engineering Sciences, vol. 28, no. 2, pp. 299–312, 2022, doi: 10.5505/pajes.2021.62687.

M. A. Rosid, A. S. Fitrani, I. R. I. Astutik, N. I. Mulloh, and H. A. Gozali, “Improving Text Preprocessing for Student Complaint Document Classification Using Sastrawi,†in IOP Conference Series: Materials Science and Engineering, Institute of Physics Publishing, Jul. 2020, pp. 1–6. doi: 10.1088/1757-899X/874/1/012017.

M. Ayu and A. Muhendra, “Preprocessing of Slang Words for Sentiment Analysis on Public Perceptions in Twitter,†2023. doi: 10.5772/intechopen.113725.

H. Imaduddin, F. Y. A’la, and Y. S. Nugroho, “Sentiment Analysis in Indonesian Healthcare Applications using IndoBERT Approach,†IJACSA, vol. 14, no. 8, pp. 113–117, 2023.

K. L. Tan, C. P. Lee, K. S. M. Anbananthen, and K. M. Lim, “RoBERTa-LSTM: A Hybrid Model for Sentiment Analysis With Transformer and Recurrent Neural Network,†IEEE Access, vol. 10, pp. 21517–21525, 2022, doi: 10.1109/ACCESS.2022.3152828.

N. Gupta, “A Pre-Trained Vs Fine-Tuning Methodology in Transfer Learning,†Journal of Physics, vol. 1947, no. 1, pp. 1–8, 2021.

H. Wang, L. Zhang, K. Yin, H. Luo, and J. Li, “Landslide identification using machine learning,†Geoscience Frontiers, vol. 12, no. 1, pp. 351–364, 2021, doi: https://doi.org/10.1016/j.gsf.2020.02.012.

S. F. M. Radzi, M. K. A. Karim, M. I. Saripan, M. A. A. Rahman, I. N. C. Isa, and M. J. Ibahim, “Hyperparameter tuning and pipeline optimization via grid search method and tree-based autoML in breast cancer prediction,†J Pers Med, vol. 11, no. 10, Oct. 2021, doi: 10.3390/jpm11100978.

A. R. M. Rom, N. Jamil, and S. Ibrahim, “Multi objective hyperparameter tuning via random search on deep learning models,†Telkomnika, vol. 22, no. 4, pp. 956–968, Aug. 2024.

H. Cho, Y. Kim, E. Lee, D. Choi, Y. Lee, and W. Rhee, “Basic Enhancement Strategies When Using Bayesian Optimization for Hyperparameter Tuning of Deep Neural Networks,†IEEE Access, vol. 8, pp. 52588–52608, 2020, doi: 10.1109/ACCESS.2020.2981072.

U. Khairani, V. Mutiawani, and H. Ahmadian, “Pengaruh Tahapan Preprocessing Terhadap Model Indobert Dan Indobertweet Untuk Mendeteksi Emosi Pada Komentar Akun Berita Instagram,†Jurnal Teknologi Informasi dan Ilmu Komputer, vol. 11, no. 4, pp. 887–894, Aug. 2024, doi: 10.25126/jtiik.1148315.

S. Dharmawan, ) Viny, C. Mawardi, ) Novario, and J. Perdana, “Klasifikasi Ujaran Kebencian Menggunakan Metode FeedForward Neural Network (IndoBERT),†pp. 1–6, 2023.

Wildan Amru Hidayat and V. R. S. Nastiti, “Perbandingan Kinerja Pre-Trained Indobert-Base Dan Indobert-Lite Pada Klasifikasi Sentimen Ulasan Tiktok Tokopedia Seller Center Dengan Model Indobert,†Jurnal Sistem Informasi, vol. 11, no. 2, pp. 13–20, Sep. 2024, doi: 10.30656/jsii.v11i2.9168.

Unduhan

Telah diserahkan

11-11-2024

Diterima

14-01-2025

Diterbitkan

02-02-2025

Cara Mengutip

[1]
E. M. Pusung dan I. N. Dewi, “Optimasi RoBERTa dengan Hyperparameter Tuning untuk Deteksi Emosi berbasis Teks”, TEKNOSI, vol. 10, no. 3, hlm. 226–233, Feb 2025.

Terbitan

Bagian

Articles