Natural Language Processing of Unstructured Healthcare Data for Predicting Heart Failure in Individuals with Type 2 Diabetes
Background/Objectives: Type 2 diabetes mellitus (T2DM) is a multisystemic disease with overlapping metabolic, renal, and cardiovascular effects. Within the Diabetic@ project, which aims to characterize individuals with T2DM using real-world data extracted from electronic health records (EHRs), this substudy sought to develop a predictive model for two-year heart failure (HF) risk. Methods: Multicenter, retrospective study including T2DM individuals across eight Spanish hospitals (2013–2018). Data were extracted exclusively from EHRs’ unstructured free text using clinical natural language processing (cNLP) and mapped to SNOMED CT. At inclusion, individuals were categorized as having or not prevalent HF (pHF). Predictive modeling was performed in non-pHF to assess two-year risk of developing HF, termed incident HF (iHF). Logistic regression (LR), decision trees, random forest, and XGBoost were compared, selecting for accuracy and interpretability. Results: Of 588,756 individuals with T2DM, 84,197 (14.3%) had pHF. Among non-pHF, 353,371 (60%) were used for model development (90.7% training, 9.3% validation). iHF occurred in 13.6% of the training set and 11.4% of the validation set. Ischemic heart disease was present in 16.2% overall, 37.9% in pHF, and 12.6% in non-pHF. Glycosylated hemoglobin data was rarely reported (<15%). LR achieved the best performance (AUC-ROC 0.73) using 27 predictors. Reduced 12- and clinically refined 9-predictor models performed similarly, with the latter implemented in a web-based tool. Conclusions: Unstructured data from EHRs enabled development of a two-year HF risk model for individuals with T2DM, underscoring the potential of cNLP for risk stratification across the cardiovascular–renal–metabolic spectrum.
Authors
- John Sanchez
- David E. Barajas Galindo (ORCID: https://orcid.org/0000-0002-4728-2346)
- Gloria Cánovas Molina
- L Olmedo (ORCID: https://orcid.org/0000-0002-7953-6611)
- José Antonio Balsa Barro
- Miguel Ángel Brito-Sanfiel (ORCID: https://orcid.org/0000-0002-4748-9777)
- Belén Pimentel (ORCID: https://orcid.org/0000-0003-4194-9231)
- Matilde Rubio Almanza
- Daniel Salvador (ORCID: https://orcid.org/0000-0002-9898-7709)
- Juan Francisco Merino-Torres (ORCID: https://orcid.org/0000-0002-0191-4504)
- Claudia Maté
- Miren Sequera Mutiozabal
- Ana Pérez Domínguez (ORCID: https://orcid.org/0009-0005-8636-5733)
- Antonio Jesús Blanco-Carrasco
- L Perez De Isla
- Juan F. Navarro-González
- Víctor Latorre Garrido (ORCID: https://orcid.org/0009-0009-3783-8230)
- Santiago Tofé Povedano
- Dídac Mauricio (ORCID: https://orcid.org/0000-0002-2868-0250)
Institutions
- Universidad de La Laguna (ES)
- Instituto de Salud Carlos III (ES)
- Hospital de Sant Pau (ES)
- Hospital Clínico San Carlos (ES)
- Hospital Universitari i Politècnic La Fe (ES)
- Hospital Universitario Nuestra Señora de Candelaria (ES)
- Universidad Fernando Pessoa Canarias (ES)
- Hospital Universitario Puerta de Hierro Majadahonda (ES)
- Hospital Clínic de Barcelona (ES)
- Hospital Universitario de Fuenlabrada (ES)
- AstraZeneca (Spain) (ES)
- Hospital Universitario Son Espases (ES)
- Hospital Universitario Río Hortega (ES)
- Hospital Universitario de León (ES)
- Hospital Universitario Infanta Sofía (ES)
- Instituto de Investigación Sanitaria La Fe (ES)
- Covance (United States) (US)
Publication Details
- Journal
- Journal of Clinical Medicine
- Published
- 2026-04-25
- DOI
- https://doi.org/10.3390/jcm15093287
- Primary Topic
- Machine Learning in Healthcare
- Type
- article
- Field-Weighted Citation Impact
- 0.00