A Comparative Evaluation of Machine Learning and Deep Learning Models for Detecting Depressive behavior on X

Authors

Ainun Najwa Mohd Pauzi

Fakulti Kecerdasan Buatan dan Keselamatan Siber, Universiti Teknikal Malaysia Melaka Hang Tuah Jaya, 76100 Durian Tunggal, Melaka (Malaysia)

Abdul Syukor Mohamad Jaya

Fakulti Kecerdasan Buatan dan Keselamatan Siber, Universiti Teknikal Malaysia Melaka Hang Tuah Jaya, 76100 Durian Tunggal, Melaka (Malaysia)

Article Information

DOI: 10.47772/IJRISS.2026.100900616

Subject Category: Language Education

Volume/Issue: 10/9 | Page No: 9011-9019

Publication Timeline

Submitted: 2026-09-24

Accepted: 2026-10-01

Published: 2026-10-17

Abstract

Early detection of mental health concerns through social media platforms like X offers significant potential for proactive intervention. However, identifying nuanced emotional and psychological distress from short, informal texts remains a complex challenge. This study aims to bridge this gap by developing and comprehensively evaluating a spectrum of machine learning, deep learning, and transformer-based models for detecting depressive behavior from X posts. A robust natural language processing (NLP) pipeline was established, encompassing data cleaning, text preprocessing, feature extraction, and classification. Four distinct architectures were investigated: Logistic Regression, Linear Support Vector Machine (SVM), CNN-LSTM, and Fine-Tuned Distil BERT. Traditional models utilized TF-IDF representations, while deep learning and transformer models employed token-based representations. Model performance was rigorously benchmarked using accuracy, precision, recall, and F1-score. Experimental results reveal that all models achieved high efficacy with accuracies exceeding 96%. Notably, the Fine-Tuned Distil BERT secured the best overall performance with an accuracy of 97.46% and an F1-score of 96.68%, whereas Linear SVM demonstrated exceptional sensitivity with the highest recall of 97.05%. These findings demonstrate that transformer-based models and advanced NLP pipelines significantly enhance the reliability of automated mental health screening on social media, providing a scalable foundation for intelligent, text-based psychological monitoring systems.

Keywords

Depression Detection, Natural Language Processing (NLP), Transformer Models, Machine Learning

Downloads

References

1. Samsudin, S., Ismail, R., Mohd Daud, S. N., & Yahya, S. (2024). The prevalence and underlying factors of mental health disorders in youth. Journal of Affective Disorders Reports, 15, 100680. [Google Scholar] [Crossref]

2. Russell, S., & Norvig, P. (2021). Artificial Intelligence: A Modern Approach (4th ed.). Pearson. [Google Scholar] [Crossref]

3. Biswas, S., & Hasija, Y. (2022). Predicting depression through social media. Lecture Notes on Data Engineering and Communications Technologies, 112, 45-58. [Google Scholar] [Crossref]

4. Cavazos-Rehg, P. A., Krauss, M. J., Sowles, S., Connolly, S., Rosas, C., Miller, M. B., & Bierut, L. J. (2016). A content analysis of depression-related tweets. Computers in Human Behavior, 54, 351-357. [Google Scholar] [Crossref]

5. Gu, L., Li, M., & Li, Y. (2026). Linguistic markers of depression and emergent self-stigma in online self-disclosures: A mixed-methods study on Chinese social media. Journal of Affective Disorders, 395, 112-123. [Google Scholar] [Crossref]

6. Adugna, T. D., Ramu, A., & Haldorai, A. (2024). A review of pattern recognition and machine learning. Journal of Machine and Computing, 4(1), 12-25. [Google Scholar] [Crossref]

7. Chatterjee, M., Kumar, P., Samanta, P., & Sarkar, D. (2022). Suicide ideation detection from online social media: A multi-modal feature based technique. International Journal of Information Management Data Insights, 2(2), 100095. [Google Scholar] [Crossref]

8. Ahmed, M., Ansari, M., Qadir, A., & Hashmi, D. (2025). Depression detection using machine learning techniques on X/Twitter data. International Journal of Information Technology and Computer Engineering, 13, 225–232. [Google Scholar] [Crossref]

9. Alphonsa Sini, P. J., & Sherly, K. K. (2023). Early detection of anxiety, depression and stress among potential patients using machine learning and deep learning models. Proceedings of the 2nd International Conference on Computational Systems and Communication (ICCSC), 104-110. [Google Scholar] [Crossref]

10. Chiong, R., Budhi, G. S., Dhakal, S., & Cambria, E. (2021). Combining sentiment lexicons and content-based features for depression detection. IEEE Intelligent Systems, 36(6), 99-105. [Google Scholar] [Crossref]

11. Amanat, A., Rizwan, M., Javed, A. R., Abdelhaq, M., Alsaqour, R., Pandya, S., & Sujatha, R. (2022). Deep learning for depression detection from textual data. Electronics (Switzerland), 11(5), 780. [Google Scholar] [Crossref]

12. Prabhakar, K., & Kavitha, V. (2024). An evolutionary approach for depression detection from Twitter big data using a novel deep learning model with attention based feature learning mechanism. Automatika, 65(2), 512-524. [Google Scholar] [Crossref]

13. Tejaswini, V., Babu, K. S., & Sahoo, B. (2024). Depression detection from social media text analysis using natural language processing techniques and hybrid deep learning model. ACM Transactions on Asian and Low-Resource Language Information Processing, 23(1), 1-22. [Google Scholar] [Crossref]

14. Patkar, U. C., Sharma, R., & Singh, K. (2024). Object and sentiment pattern recognition using machine learning and deep learning. International Journal of Intelligent Systems and Applications in Engineering, 12(1s), 415-422. [Google Scholar] [Crossref]

15. Turuba, R., Johnson, P., & Smith, L. (2025). A summative content analysis of mental health-related content on social media platforms. Digital Health, 11, 1-14. [Google Scholar] [Crossref]

16. Angskun, T., Tipprasert, S., Thippongtorn, A., & Angskun, J. (2024). D₂X: Depression detection system through X using hybrid machine learning. IEEE Access, 12, 172820–172831. [Google Scholar] [Crossref]

17. Tejaswini, V., Babu, K. S., & Sahoo, B. (2024). Depression detection from social media text analysis using natural language processing techniques and hybrid deep learning model. ACM Transactions on Asian and Low-Resource Language Information Processing, 23(1), 1-22. [Google Scholar] [Crossref]

Metrics

Views & Downloads

Similar Articles