Development and External Validation of a Treatment-Adjusted Machine Learning Model for Precision Allocation of Group-Based Depression Care Among People Living with HIV in Uganda
Open Access
- 6 April 2026
- journal article
- Published by F1000 Research Ltd in Wellcome Open Research
- Vol. 11, 203
Abstract
Background Group-based depression care is widely used in HIV services in Uganda, yet some patients remain symptomatic. Uniform intervention allocation may not match individual needs and can strain scarce mental health resources. We developed and externally validated a treatment-adjusted machine learning model to predict six-month depression non-remission and support precision allocation of care. Methods We analyzed data from 1,140 adults living with HIV and significant depression symptoms enrolled across 30 HIV clinics in the SEEK-GSP trial (PACTR201608001738234). Participants were assigned to Group Support Psychotherapy (GSP) or Group HIV Education (GHE). The primary outcome was six-month depression non-remission, defined as Self-Reporting Questionnaire (SRQ) score ≥ 6 and a functional impairment score < 9. Treatment assignment was included to enable risk estimation adjusted for treatment. Three machine learning models (Elastic Net, Random Forest, and XGBoost) were trained on baseline data from Gulu and Kitgum and externally validated in Pader district, with the best-performing parsimonious model selected to inform precision allocation. Calibration was evaluated on the external set using slope, intercept, Brier score, and the area under the receiver operating characteristic curve [AUC], with isotonic regression and Platt scaling applied for recalibration. Results All models demonstrated excellent discrimination in geographically distinct external validation (AUC 0.974–0.980). XGBoost achieved strong overall classification performance in Pader district (AUC 0.979; accuracy 0.920; sensitivity 0.865; specificity 0.970), supporting reliable identification of individuals at risk of non-remission. Post-calibration isotonic regression improved probability alignment (slope 1.703 to 1.00; Brier 0.070 to 0.015; AUC 0.986). Across modeling approaches, consistent predictors of non-remission included treatment assignment, older age, economic vulnerability (lower income, savings, and employment instability), stigma, low perceived social support, and maladaptive coping patterns. Conclusion Treatment-adjusted machine learning models can accurately predict six-month depression non-remission and provide a foundation for precision allocation of group-based depression care within HIV services in low-resource settings.Keywords
Funding Information
- Wellcome Trust
- Grand Challenges Canada (0770-05)
- MQ Mental Health Research (MQ15FIP100024)
This publication has 60 references indexed in Scilit:
- Machine Learning Model for Response to Internet-Delivered CBT vs Antidepressant MedicationJAMA Network Open, 2025
- Prospective prediction of first onset of major depressive disorder in midlife using machine learningSocial Psychiatry and Psychiatric Epidemiology, 2025
- Absolute and relative outcomes of psychotherapies for eight mental disorders: a systematic review and meta‐analysisWorld Psychiatry, 2024
- Psychotherapies for depression: a network meta‐analysis covering efficacy, acceptability and long‐term outcomes of all main treatment typesWorld Psychiatry, 2021
- The promise of machine learning in predicting treatment outcomes in psychiatryWorld Psychiatry, 2021
- Variable selection – A review and recommendations for the practicing statisticianBiometrical Journal, 2018
- Psychosocial group interventions to improve psychological well-being in adults living with HIVCochrane Database of Systematic Reviews, 2017
- Depression, Alcohol Use and Adherence to Antiretroviral Therapy in Sub-Saharan Africa: A Systematic ReviewAIDS and Behavior, 2011
- Development of a Brief Scale to Measure AIDS-Related Stigma in South AfricaAIDS and Behavior, 2005
- Index for rating diagnostic testsCancer, 1950