Klasifikasi Teks Depresi Pada Media Sosial Menggunakan Convolutional Neural Network Dengan Fasttext Embedding

Authors

  • Azki Hamdi Universitas Merdeka Pasuruan, Indonesia
  • Mohammad Zoqi Sarwani Universitas Merdeka Pasuruan, Indonesia
  • Anang Aris Widodo Universitas Merdeka Pasuruan, Indonesia

DOI:

https://doi.org/10.35889/progresif.v22i3.3899

Keywords:

Depresi, Media Sosial, Natural Language Processing, Convolutional Neural Network, FastText Embedding

Abstract

Depression is a persistent mood disorder that significantly impacts an individual's functioning, and its prevalence is becoming increasingly concerning among adolescents (the "Strawberry Generation"). Expressions of this psychological distress have largely migrated to social media in the form of unstructured text posts laden with informal terms, abbreviations, and typos. These linguistic characteristics pose "Out-of-Vocabulary" (OOV) challenges for traditional classification models. This study proposes integrating FastText word embeddings—which utilize subword information—to enhance feature representation, combined with a Convolutional Neural Network (CNN) architecture as the primary classifier. Using the "Student Depression Text" secondary dataset from Kaggle (comprising 7,489 entries), class imbalance was addressed exclusively within the training data using the Random Oversampling technique. Experimental results demonstrate that the proposed model achieved an overall accuracy of 95%, with Precision, Recall, and F1-Score values ​​for the depression class of 90%, 80%, and 84%, respectively. The integration of CNN and pre-trained FastText proved to be a reliable and efficient solution for managing the complexities of digital language in the context of early mental health detection.

Keywords: Depression; Social Media; Natural Language Processing; Convolutional Neural Network; FastText Embedding.

Abstrak

Depresi merupakan gangguan suasana hati persisten yang secara signifikan memengaruhi fungsi fungsional individu dan prevalensinya kian mengkhawatirkan pada kelompok remaja (Strawberry Generation). Ekspresi tekanan psikologis ini kini banyak bermigrasi ke media sosial dalam bentuk unggahan teks tidak terstruktur yang sarat akan istilah non-formal, singkatan, dan salah ketik (typo). Karakteristik bahasa tersebut memicu kendala Out-of-Vocabulary (OOV) pada model klasifikasi tradisional. Penelitian ini mengusulkan integrasi word embedding FastText berbasis informasi tingkat sub-kata (subword information) untuk memperkuat representasi fitur, yang dikombinasikan dengan arsitektur Convolutional Neural Network (CNN) sebagai pengklasifikasi utama. Menggunakan dataset sekunder "Student Depression Text" sebanyak 7.489 entri dari Kaggle, ketidakseimbangan kelas diatasi secara eksklusif pada data latih menggunakan teknik Random Oversampling. Hasil eksperimen menunjukkan bahwa model yang diusulkan meraih akurasi keseluruhan sebesar 95%, dengan nilai Precision, Recall, dan F1-Score untuk kelas depresi masing-masing sebesar 90%, 80%, dan 84%. Integrasi CNN dan pre-trained FastText terbukti efektif menjadi solusi jalan tengah yang andal dan efisien dalam menangani kompleksitas bahasa digital untuk deteksi dini kesehatan mental.

Author Biographies

Azki Hamdi, Universitas Merdeka Pasuruan

Informatika

Mohammad Zoqi Sarwani, Universitas Merdeka Pasuruan

Informatika

Anang Aris Widodo, Universitas Merdeka Pasuruan

Informatika

References

[1] T. Nirmalawati and E. Qurniyawati, “Mental Health of Adolescents in the Strawberry Generation: A Bibliometric Analysis,” J. Promkes, vol. 13, no. 2, pp. 250–256, Sep. 2025, doi: 10.20473/jpk.V13.I2.2025.250-256.

[2] A. P. Association, “Diagnostic and Statistical Manual of Mental Disorders (DSM-5®),” Am. Psychiatr. Assoc., 2013.

[3] K. Rahayu, V. Fitria, D. Septhya, R. Rahmaddeni, and L. Efrizoni, “Klasifikasi Teks untuk Mendeteksi Depresi dan Kecemasan pada Pengguna Twitter Berbasis Machine Learning,” MALCOM Indones. J. Mach. Learn. Comput. Sci., vol. 3, no. 2, pp. 108–114, Sep. 2023, doi: 10.57152/malcom.v3i2.780.

[4] M. Ridha, M. K. Abdur Rohman, D. Agustin, D. H. Shaputra, Y. Manayla, and A. H. Malikah, “Penerapan Machine Learning untuk Klasifikasi Teks Depresi pada Kesehatan Mental dengan SVM, TF-IDF, dan Chi-Square,” J. Software, Hardw. Inf. Technol., vol. 5, no. 2, pp. 171–182, Jun. 2025, doi: 10.24252/shift.v5i2.210.

[5] Ivan Dwi Nugraha and Y. Azhar, “Deteksi Depresi Pengguna Twitter Indonesia Menggunakan LSTM-RNN,” J. Nas. Pendidik. Tek. Inform., vol. 11, no. 3, pp. 320–329, 2022, doi: 10.23887/janapati.v11i3.50674.

[6] Rahmadika Putri Tresyani, D. Wahyu Utomo, and N. Maldini, “Deteksi Dini Gangguan Kesehatan Mental dengan Model Bert dan Algoritma Xgboost,” Infotekmesin, vol. 16, no. 1, pp. 93–98, 2025, doi: 10.35970/infotekmesin.v16i1.2535.

[7] P. Bojanowski, E. Grave, A. Joulin, and T. Mikolov, “Enriching Word Vectors with Subword Information,” Trans. Assoc. Comput. Linguist., vol. 5, pp. 135–146, 2017, doi: 10.1162/tacl_a_00051.

[8] Y. Kim, “Convolutional neural networks for sentence classification,” EMNLP 2014 - 2014 Conf. Empir. Methods Nat. Lang. Process. Proc. Conf., pp. 1746–1751, 2014, doi: 10.3115/v1/d14-1181.

[9] W. M. Baihaqi and A. Munandar, “Sentiment Analysis of Student Comment on the College Performance Evaluation Questionnaire Using Naïve Bayes and IndoBERT,” JUITA J. Inform., vol. 11, no. 2, p. 213, Nov. 2023, doi: 10.30595/juita.v11i2.17336.

[10] I. B. R. W. Manuaba, R. Dwiyansaputra, and M. Z. Hamidi, “Pendekatan Sentimen Berbasis Aspek Pada Ulasan Sirkuit Mandalika Menggunakan Cnn Dan Representasi Fasttext,” J. Teknol. Informasi, Komputer, dan Apl. (JTIKA ), vol. 7, no. 1, pp. 132–141, 2025, doi: 10.29303/jtika.v7i1.460.

[11] E. Saraswati and Muljono, “Deteksi Emosi Pada Twitter Berbasis Fasttext: Evaluasi Performa Arsitektur Cnn Dan Gru,” Rabit J. Teknol. dan Sist. Inf. Univrab, vol. 11, no. 1, pp. 1175–1186, 2026, doi: 10.36341/rabit.v11i1.7252.

[12] M. T. Maulana, L. Muflikhah, and T. N. Fatyanosa, “Analisis Sentimen Pengguna Indodax Menggunakan FastText dan Convolutional Neural Network (CNN),” vol. 9, no. 6, pp. 2548–964, 2025, [Online]. Available: http://j-ptiik.ub.ac.id

[13] A. Lestari, Ade Irma Purnamasari, Agus Bahtiar, and Edi Tohidi, “Sentiment analysis to classify TikTok Shop Users on Twitter with Naïve Bayes Classifier Algorithm,” J. Artif. Intell. Eng. Appl., vol. 4, no. 2, pp. 815–822, Feb. 2025, doi: 10.59934/jaiea.v4i2.748.

[14] Firna, “Implementasi model Long Short-Term Memory (LSTM) untuk klasifikasi multi-label ujaran kebencian pada tweet bahasa Indonesia,” Etheses, 2026.

[15] G. F. Situmorang and R. Purba, “Deteksi Potensi Depresi dari Unggahan Media Sosial X Menggunakan IndoBERT,” Build. Informatics, Technol. Sci., vol. 6, no. 2, pp. 649–661, 2024, doi: 10.47065/bits.v6i2.5496.

[16] İ. Baydili, B. Tasci, and G. Tasci, “Deep Learning-Based Detection of Depression and Suicidal Tendencies in Social Media Data with Feature Selection,” Behav. Sci. (Basel)., vol. 15, no. 3, p. 352, Mar. 2025, doi: 10.3390/bs15030352.

[17] K. Bajaj, M. Kumar, S. Jain, V. Bhardwaj, and S. Walia, “Enhancing Suicide Risk Prediction through BERT: Leveraging Textual Biomarkers for Early Detection,” Int. J. Intell. Syst. Appl., vol. 17, no. 2, pp. 101–111, Apr. 2025, doi: 10.5815/ijisa.2025.02.06.

[18] S. N. Saputra, G. G. Setiaji, and M. T. A. C. Widiyanto, “Perbandingan Kinerja RNN dan CNN Dalam Klasifikasi Sentimen Ulasan Pengguna Aplikasi di Play Store,” J. Comput. Syst. Informatics, vol. 6, no. 1, pp. 349–362, 2024, doi: 10.47065/josyc.v6i1.6408.

[19] “Depression Detection on Multimodal Data from Social Media X with FastText Feature Expansion using Hybrid Deep Learning Model CNN-BiLSTM”.

[20] R. Wesley and R. Gunawan, “Literatur Review: Metode Deep Learning Untuk Analisis Teks,” J. Mhs. Tek. Inform., vol. 8, no. 5, pp. 11020–11023, 2024.

Downloads

Published

2026-07-15

How to Cite

Hamdi, A., Zoqi Sarwani, M., & Aris Widodo, A. (2026). Klasifikasi Teks Depresi Pada Media Sosial Menggunakan Convolutional Neural Network Dengan Fasttext Embedding. Progresif: Jurnal Ilmiah Komputer, 22(3), 807–819. https://doi.org/10.35889/progresif.v22i3.3899

Issue

Section

Articles

Citation Check

Similar Articles

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 > >> 

You may also start an advanced similarity search for this article.