An Interpretable Neuro-Fuzzy Framework for Mental Health Indicator Classification with Contextual Representation and Metaheuristic Optimization
DOI:
https://doi.org/10.62411/jcta.18001Keywords:
ANFIS, IndoBERT, Interpretability, Metaheuristic Optimization, Mental Health Text Classification, Neuro-Fuzzy Systems, Cyberbullying; Multilingual; BiLSTM; CNN; Harmonic Self-Attention; XLM-RoBERTa; Social Media, Text ClassificationAbstract
Social media text provides valuable information for analyzing mental health-related expressions. However, contextual language variation, class imbalance, and limited model interpretability remain important challenges in text classification. This study evaluates different text representations, class-imbalance handling strategies, and metaheuristic optimization within an Adaptive Neuro-Fuzzy Inference System (ANFIS) framework. A total of 19,429 Indonesian-language posts were retained after duplicate removal and label-conflict adjudication. The dataset was partitioned using a fixed group-aware split into 13,600 training, 2,914 validation, and 2,915 test records, covering four categories: Distress, Crisis, Protective, and Situational. The experiments examined lexical-statistical, distributed-semantic, and contextual representations using Plain ANFIS, class-balanced focal ANFIS (CBF-ANFIS), and its metaheuristic-optimized variants based on the Whale Optimization Algorithm (WOA) and Crow Search Algorithm (CSA). Model performance was evaluated across three random seeds and compared with a TF-IDF-based Logistic Regression baseline and direct IndoBERT fine-tuning. Direct IndoBERT achieved the highest test Macro-F1 of 0.7685 ± 0.0046, followed by preliminary Plain ANFIS (0.6942 ± 0.0011) and final CBF-ANFIS (0.6897 ± 0.0054). Although WOA and CSA improved validation Macro-F1, their mean test Macro-F1 scores were slightly lower than that of CBF-ANFIS (0.6890 and 0.6859 versus 0.6897, respectively), indicating no consistent generalization benefit. Overall, direct IndoBERT provided superior classification performance, whereas the neuro-fuzzy framework offered a structured mechanism for tracing rule activation and inference in the latent feature space. Nevertheless, these rules do not provide direct linguistic or clinical interpretations.References
T. Zhang, A. M. Schoene, S. Ji, and S. Ananiadou, “Natural language processing applied to mental illness detection: a narrative review,” npj Digit. Med., vol. 5, no. 1, p. 46, Apr. 2022, doi: 10.1038/s41746-022-00589-7.
R. Salas-Zárate, G. Alor-Hernández, M. del P. Salas-Zárate, M. A. Paredes-Valverde, M. Bustos-López, and J. L. Sánchez-Cervantes, “Detecting Depression Signs on Social Media: A Systematic Literature Review,” Healthcare, vol. 10, no. 2, p. 291, Feb. 2022, doi: 10.3390/healthcare10020291.
A. Malhotra and R. Jindal, “Deep learning techniques for suicide and depression detection from online social media: A scoping review,” Appl. Soft Comput., vol. 130, p. 109713, Nov. 2022, doi: 10.1016/j.asoc.2022.109713.
K. Mao, Y. Wu, and J. Chen, “A systematic review on automated clinical depression diagnosis,” npj Ment. Heal. Res., vol. 2, no. 1, p. 20, Nov. 2023, doi: 10.1038/s44184-023-00040-z.
H. W. Loh, C. P. Ooi, S. Seoni, P. D. Barua, F. Molinari, and U. R. Acharya, “Application of explainable artificial intelligence for healthcare: A systematic review of the last decade (2011–2022),” Comput. Methods Programs Biomed., vol. 226, p. 107161, Nov. 2022, doi: 10.1016/j.cmpb.2022.107161.
G. Huang, Y. Li, S. Jameel, Y. Long, and G. Papanastasiou, “From explainable to interpretable deep learning for natural language processing in healthcare: How far from reality?,” Comput. Struct. Biotechnol. J., vol. 24, pp. 362–373, Dec. 2024, doi: 10.1016/j.csbj.2024.05.004.
M. M. Tadesse, H. Lin, B. Xu, and L. Yang, “Detection of Depression-Related Posts in Reddit Social Media Forum,” IEEE Access, vol. 7, pp. 44883–44893, 2019, doi: 10.1109/ACCESS.2019.2909180.
J. S. L. Figuerêdo, A. L. L. M. Maia, and R. T. Calumby, “Early depression detection in social media based on deep learning and underlying emotions,” Online Soc. Networks Media, vol. 31, p. 100225, Sep. 2022, doi: 10.1016/j.osnem.2022.100225.
M. Kerasiotis, L. Ilias, and D. Askounis, “Depression detection in social media posts using transformer-based models and auxiliary features,” Soc. Netw. Anal. Min., vol. 14, no. 1, p. 196, Sep. 2024, doi: 10.1007/s13278-024-01360-4.
K. Yang, T. Zhang, and S. Ananiadou, “A mental state Knowledge–aware and Contrastive Network for early stress and depression detection on social media,” Inf. Process. Manag., vol. 59, no. 4, p. 102961, Jul. 2022, doi: 10.1016/j.ipm.2022.102961.
E. Bao, A. Pérez, and J. Parapar, “Explainable depression symptom detection in social media,” Heal. Inf. Sci. Syst., vol. 12, no. 1, p. 47, Sep. 2024, doi: 10.1007/s13755-024-00303-9.
P. P. Angelov, E. A. Soares, R. Jiang, N. I. Arnold, and P. M. Atkinson, “Explainable artificial intelligence: an analytical review,” WIREs Data Min. Knowl. Discov., vol. 11, no. 5, p. e1424, Sep. 2021, doi: 10.1002/widm.1424.
X. Gu, J. Han, Q. Shen, and P. P. Angelov, “Autonomous learning for fuzzy systems: a review,” Artif. Intell. Rev., vol. 56, no. 8, pp. 7549–7595, Aug. 2023, doi: 10.1007/s10462-022-10355-6.
L. Pickering, K. Cohen, and B. De Baets, “A Narrative Review on the Interpretability of Fuzzy Rule-Based Models from a Modern Interpretable Machine Learning Perspective,” Int. J. Fuzzy Syst., vol. 28, no. 4, pp. 1313–1332, Jun. 2026, doi: 10.1007/s40815-025-02022-z.
M. Mehrabi, B. Pradhan, H. Moayedi, and A. Alamri, “Optimizing an Adaptive Neuro-Fuzzy Inference System for Spatial Prediction of Landslide Susceptibility Using Four State-of-the-art Metaheuristic Techniques,” Sensors, vol. 20, no. 6, p. 1723, Mar. 2020, doi: 10.3390/s20061723.
I. Ahmadianfar, S. Shirvani-Hosseini, J. He, A. Samadi-Koucheksaraee, and Z. M. Yaseen, “An improved adaptive neuro fuzzy inference system model using conjoined metaheuristic algorithms for electrical conductivity prediction,” Sci. Rep., vol. 12, no. 1, p. 4934, Mar. 2022, doi: 10.1038/s41598-022-08875-w.
H. Wang, B. Chen, H. Sun, A. Li, and C. Zhou, “AnFiS-MoH: Systematic exploration of hybrid ANFIS frameworks via metaheuristic optimization hybridization with evolutionary and swarm-based algorithms,” Appl. Soft Comput., vol. 167, p. 112334, Dec. 2024, doi: 10.1016/j.asoc.2024.112334.
L. Deng and S. Liu, “Deficiencies of the whale optimization algorithm and its validation method,” Expert Syst. Appl., vol. 237, p. 121544, Mar. 2024, doi: 10.1016/j.eswa.2023.121544.
A. G. Hussien et al., “Crow Search Algorithm: Theory, Recent Advances, and Applications,” IEEE Access, vol. 8, pp. 173548–173565, 2020, doi: 10.1109/ACCESS.2020.3024108.
A. Sheta, M. Braik, H. Al-Hiary, and S. Mirjalili, “Improved versions of crow search algorithm for solving global numerical optimization problems,” Appl. Intell., vol. 53, no. 22, pp. 26840–26884, Nov. 2023, doi: 10.1007/s10489-023-04732-z.
R. Budianoor, S. W. Saputro, F. Abadi, R. A. Nugroho, and A. Farmadi, “Quantifying the Impact of Text Preprocessing on IndoBERT Fine-Tuning for Indonesian Informal Culinary Sentiment Analysis,” J. Comput. Theor. Appl., vol. 3, no. 4, pp. 564–581, May 2026, doi: 10.62411/jcta.15980.
I. N. Aqiilah, R. Saptono, and A. Syaifuddin, “Sentence-Level Sentiment Analysis of Indonesian App Reviews Using IndoBERTweet,” J. Comput. Theor. Appl., vol. 4, no. 1, pp. 74–91, Jun. 2026, doi: 10.62411/jcta.16240.
B. R. P. Darnoto and D. B. Firmawan, “Language-Similarity-Guided Transfer Fine-Tuning of Pre-trained Transformer Models for Sentiment Analysis Across 12 Indonesian Regional Languages,” J. Comput. Theor. Appl., vol. 3, no. 4, pp. 547–563, May 2026, doi: 10.62411/jcta.15975.
S. Mahmood, N. Z. Bawany, and M. R. Tanweer, “A comprehensive survey of whale optimization algorithm: modifications and classification,” Indones. J. Electr. Eng. Comput. Sci., vol. 29, no. 2, p. 899, Feb. 2023, doi: 10.11591/ijeecs.v29.i2.pp899-910.
T. Thaher, A. Sheta, M. Awad, and M. Aldasht, “Enhanced variants of crow search algorithm boosted with cooperative based island model for global optimization,” Expert Syst. Appl., vol. 238, p. 121712, Mar. 2024, doi: 10.1016/j.eswa.2023.121712.
M. Braik, H. Al-Zoubi, M. Ryalat, A. Sheta, and O. Alzubi, “Memory based hybrid crow search algorithm for solving numerical and constrained global optimization problems,” Artif. Intell. Rev., vol. 56, no. 1, pp. 27–99, Jan. 2023, doi: 10.1007/s10462-022-10164-x.
A. D. Latief, A. Jarin, M. T. Uliniansyah, E. Nurfadhilah, and D. I. N. Afra, “A Proven Sentiment Annotation Guideline for Indonesian Twitter Data,” in 2023 International Conference on Computer, Control, Informatics and its Applications (IC3INA), IEEE, Oct. 2023, pp. 31–36. doi: 10.1109/IC3INA60834.2023.10285807.
B. M. Rashed and N. Popescu, “Medical Image-Based Diagnosis Using a Hybrid Adaptive Neuro-Fuzzy Inferences System (ANFIS) Optimized by GA with a Deep Network Model for Features Extraction,” Mathematics, vol. 12, no. 5, p. 633, Feb. 2024, doi: 10.3390/math12050633.
N. Das and S. A. Begum, “An Empirical Study of Loss Functions for Aspect Category Detection in Imbalanced Data Scenario,” in 2025 10th International Conference on Signal Processing and Communication (ICSC), IEEE, Feb. 2025, pp. 247–252. doi: 10.1109/ICSC64553.2025.10968230.
H. Ren, Y. Zhao, Y. Zhang, and W. Sun, “Learning label smoothing for text classification,” PeerJ Comput. Sci., vol. 10, p. e2005, Apr. 2024, doi: 10.7717/peerj-cs.2005.
H. Lee, T. Park, and H. Kim, “Learnable Logit Adjustment for Imbalanced Semi-Supervised Learning Under Class Distribution Mismatch,” in 2025 IEEE/CVF International Conference on Computer Vision (ICCV), IEEE, Oct. 2025, pp. 2664–2674. doi: 10.1109/ICCV51701.2025.00256.
M. H. Nadimi-Shahraki, H. Zamani, Z. Asghari Varzaneh, and S. Mirjalili, “A Systematic Review of the Whale Optimization Algorithm: Theoretical Foundation, Improvements, and Hybridizations,” Arch. Comput. Methods Eng., vol. 30, no. 7, pp. 4113–4159, Sep. 2023, doi: 10.1007/s11831-023-09928-7.
Y. Meraihi, A. B. Gabis, A. Ramdane-Cherif, and D. Acheli, “A comprehensive survey of Crow Search Algorithm and its applications,” Artif. Intell. Rev., vol. 54, no. 4, pp. 2669–2716, Apr. 2021, doi: 10.1007/s10462-020-09911-9.
J. Opitz, “A Closer Look at Classification Evaluation Metrics and a Critical Reflection of Common Evaluation Practice,” Trans. Assoc. Comput. Linguist., vol. 12, pp. 820–836, Jun. 2024, doi: 10.1162/tacl_a_00675.
M. Carpita and S. Golia, “Categorical classifiers in multiclass classification with imbalanced datasets,” Stat. Anal. Data Min. ASA Data Sci. J., vol. 16, no. 4, pp. 391–405, Aug. 2023, doi: 10.1002/sam.11624.
E. Richardson, R. Trevizani, J. A. Greenbaum, H. Carter, M. Nielsen, and B. Peters, “The receiver operating characteristic curve accurately assesses imbalanced datasets,” Patterns, vol. 5, no. 6, p. 100994, Jun. 2024, doi: 10.1016/j.patter.2024.100994.
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2026 Haeni Budiati, Sunneng Sandino Berutu, Agustinus Rudatyo Himamunanto, Faisal Yahya, Mosiur Rahaman

This work is licensed under a Creative Commons Attribution 4.0 International License.














