Indonesian Social Media Text Classification for Mental Health Risk Detection Using Bidirectional LSTM
Keywords:
Bidirectional LSTM; Mental Health Detection; Indonesian Social Media; Text Classification; Deep Learning; Health Informatics
Abstract
Mental health disorders, particularly depression and anxiety, have become increasingly prevalent in Indonesia, affecting millions of individuals across all age groups. However, limited access to mental health professionals and persistent social stigma frequently prevent timely early detection and intervention. Social media platforms serve as digital diaries where Indonesian users express their emotional states, presenting a unique opportunity for automated mental health risk screening. This study proposes a deep learning approach using Bidirectional Long Short-Term Memory (BiLSTM) for classifying Indonesian social media text into three mental health risk categories: Normal (low risk), Depression (high risk), and Anxiety (moderate risk). Unlike standard LSTM, which processes text in a single direction, BiLSTM captures contextual information from both forward and backward directions — a critical advantage for understanding nuanced expressions in Indonesian informal language. A dataset of 1,488 Indonesian text samples (500 Normal, 494 Depression, 494 Anxiety) was collected from Twitter and labeled by expert annotators with an inter-annotator agreement (Cohen's Kappa) of 0.87. Comprehensive text preprocessing was applied, including case folding, noise removal, stopword elimination using NLTK, and stemming using Sastrawi. The proposed BiLSTM model was evaluated against three baseline methods: Naïve Bayes, Support Vector Machine (SVM), and standard LSTM. Experimental results demonstrate that BiLSTM achieves superior performance with 87.5% accuracy, 86.8% precision, 86.2% recall, and 86.5% F1-score, outperforming standard LSTM by 4.2% and SVM by 12.1%. A desktop application with a graphical user interface was developed for practical deployment, featuring real-time detection, confidence scoring, and prediction history logging. This research contributes an effective, reproducible, and deployable deep learning-based screening tool for mental health risk detection from Indonesian social media text.
Downloads
References
[2] Kementerian Kesehatan, “Survei Kesehatan Indonesia,” 2023.
[3] D. Reportal, “DIGITAL 2024,” 2024.
[4] T. Mikolov, G. Corrado, K. Chen, and J. Dean, “Efficient Estimation of Word Representations in Vector Space,” pp. 1–12, 2013, [Online]. Available: https://arxiv.org/abs/1301.3781
[5] S. Hochreiter and J. Schmidhuber, “Long Short-Term Memory,” vol. 9, no. 8, pp. 1–32, 1997, [Online]. Available: https://arxiv.org/abs/1301.3781
[6] A. Graves and J. Schmidhuber, “Framewise Phoneme Classification with Bidirectional LSTM and Other Neural Network Architectures,” vol. 18, no. 5–6, pp. 602–610, 2005, [Online]. Available: https://www.sciencedirect.com/science/article/abs/pii/S0893608005001206
[7] Z. Huang, W. Xu, and K. Yu, “Bidirectional LSTM-CRF Models for Sequence Tagging,” Arxiv, 2015.
[8] Y. Wang, M. Huang, L. Zhao, and X. Zhu, “Attention-based LSTM for Aspect-level Sentiment Classification,” pp. 606–615, 2016.
[9] G. Coppersmith, R. Leary, P. Crutchley, and A. Fine, “Natural Language Processing of Social Media as Screening for Suicide Risk,” 2018, doi: 10.1177/1178222618792860.
[10] K. S. Nugroho et al., “DETEKSI DEPRESI DAN KECEMASAN PENGGUNA TWITTER,” no. Ciastech, pp. 287–296, 2021.
[11] K. K. Putri and E. B. Setiawan, “Depression Detection in Indonesian X Social Media Text using Convolutional Neural Networks and Long Short-Term Memory with TF- IDF and FastText Methods,” vol. 6, no. 2, pp. 557–574, 2025.
[12] M. Fadhel and W. Maharani, “Depression Detection of Users in Social Media X using IndoBERTweet,” vol. 8, no. 2, pp. 885–891, 2024.
[13] A. M. Alayba, V. Palade, M. England, and R. Iqbal, “Arabic Language Sentiment Analysis on Health Services”.
[14] M. D. Purbolaksono, F. D. Reskyadita, and A. A. Suryani, “Indonesian Text Classification using Back Propagation and Sastrawi Stemming Analysis with Information Gain for Selection Feature,” vol. 10, no. 1, pp. 234–238, 2020.
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2026 Arief Rahman Hakim Arief, Yuni Franciska Br. Tarigan, Khairul Fadhli MargolangAuthors who publish in Hanif Journal of Information Systems agree to the following terms:
- Authors retain copyright and grant the journal right of first publication with the work simultaneously licensed under a Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) License that allows others to share the work with an acknowledgment of the work's authorship and initial publication in this journal.
- Authors are able to enter into separate, additional contractual arrangements for the non-exclusive distribution of the journal's published version of the work (e.g., post it to an institutional repository or publish it in a book), with an acknowledgment of its initial publication in this journal.
- Authors are permitted and encouraged to post their work online (e.g., in institutional repositories or on their website) prior to and during the submission process, as it can lead to productive exchanges, as well as earlier and greater citation of published work (See The Effect of Open Access).
Similar Articles
- Arief Rahman Hakim, Ahmad Riady Hasibuan, Pipit Putri Hariani, Implementation of Multimedia Development Life Cycle in Learning Media Applications for Children with Mental Disabilities , Hanif Journal of Information Systems : Vol. 2 No. 1 (2024): August Edition
- Ilham Prastia, Mulkan Azhari, Development of Virtual Reality-Based Computer Assembly Simulation Learning Media , Hanif Journal of Information Systems : Vol. 3 No. 1 (2025): August Edition
- Akhmad Jayadi, Kurniawan Saputra, Ahmad Rofi'i, Improving the Accuracy of Lettuce and Weed Classification Based on MobileNetV2 Features Through Segmentation , Hanif Journal of Information Systems : Vol. 3 No. 2 (2026): February Edition
- Leony Ayu Diah Pasha, Zainal Azis, Predicting The Risk of Online Sales Fraud with The Naïve Bayes Approach on Facebook Social Media , Hanif Journal of Information Systems : Vol. 2 No. 2 (2025): February Edition
- Muhammad Rizki Suma, Yoshida Sary, Text Processing Application on Images using Modification of LSB and ROTI3 Methods , Hanif Journal of Information Systems : Vol. 2 No. 2 (2025): February Edition
- Muhammad Nauval Asyqar Ridwan Ritonga, Halim Maulana, IoT Based Industrial Waste Monitoring System Design with Data Visualization on A Web Application Using The Supervised Learning Method , Hanif Journal of Information Systems : Vol. 3 No. 1 (2025): August Edition
- Al-Khowarizmi Al-Khowarizmi, Asrar Aspia Manurung, Mulkan Azhari, Design of an Application to Calculate Student Grades in Learning Logic Informatics Propositional Calculus Material , Hanif Journal of Information Systems : Vol. 1 No. 1 (2023): August Edition
- nurkumalalubis, Mulkan Azhari, Machine Learning-Based Phishing Email Detection: A Comparative Study of Support Vector Machine and Random Forest , Hanif Journal of Information Systems : Vol. 3 No. 2 (2026): February Edition
- Yoga Pramana, Halim Maulana, SEO (Search Engine Optimization) Finding Growth Opportunities in Organic Traffic on the KAIA Media.id Website , Hanif Journal of Information Systems : Vol. 3 No. 2 (2026): February Edition
- Ahmad Asadel, Andi Zulherry, Detecting Zero-Width Characters Obfuscated in Phishing URLs using the XGBOOST Algorithm , Hanif Journal of Information Systems : Vol. 3 No. 1 (2025): August Edition
You may also start an advanced similarity search for this article.









