Abstract
Electronic health records (EHRs) serve as a digital repository storing comprehensive medical information about patients. Representation learning for EHRs plays a crucial role in healthcare applications. In this paper, we propose a Multimodal Heterogeneous Graph-enhanced Representation Learning, denoted as MHGRL, aimed at learning effective EHR representations. To address the challenge posed by data insufficiency of EHRs, MHGRL utilizes a multimodal heterogeneous graph to model an EHR. Specifically, we construct a heterogeneous graph for each EHR and enrich it by incorporating multimodal information with medical ontology and textual notes. With the integration of pre-trained model, graph neural network, and attention mechanism, MHGRL effectively incorporates both node attributes and structural information across a multimodal heterogeneous graph. Moreover, we employ contrastive learning to ensure the consistency of representations for similar EHRs and improve the model robustness. The experimental results show that MHGRL outperforms all baselines on two real clinical datasets in downstream tasks, including EHR clustering and disease prediction.
Introduction
Electronic Health Records (EHRs) are a goldmine for clinical research, but they are notoriously difficult to model. They are often sparse, high-dimensional, and restricted by privacy regulations that limit the amount of data available for training deep learning models.
Existing approaches usually fall into two traps: they either treat medical codes (like diagnoses or medications) as simple sequences, ignoring the complex structural relationships between them, or they focus on a single data type (e.g., just the codes or just the clinical notes). There is a significant gap in effectively fusing "internal" patient data with "external" medical knowledge—such as hierarchical ontologies and descriptive text—to create a holistic view of a patient's health state.
Methodology
The authors propose MHGRL, which operates in four distinct stages to transform raw EHR data into robust patient embeddings.
1. Multimodal Heterogeneous Graph (MHG) Construction
Instead of a flat list of features, an EHR is modeled as a graph where nodes represent diagnoses, procedures, and medications. Edges are drawn based on a Medical Knowledge Graph (MKG) that captures real-world clinical relationships.
2. Multimodal Encoding
To enrich these nodes, the authors use a two-pronged approach:
- Textual Notes: Since raw clinical notes are often messy, the researchers use an LLM (ChatGPT) to generate clean, brief definitions for every medical code, which are then embedded using BERT.
- Medical Ontology: They use a Graph Attention Network (GAT) to process hierarchical medical structures (like ICD-9), using both bottom-up and top-down strategies to capture the context of a code within its broader medical category.
3. Neighbor Aggregation & Node Combination
The model uses Graph Neural Networks (GNNs) to let nodes "talk" to their neighbors, capturing high-order relationships (e.g., how a specific medication relates to a specific procedure). An attention mechanism then weighs these nodes to produce a single, dense vector representing the entire EHR.
4. Contrastive Learning
To improve model robustness, the authors employ a contrastive loss. This forces the model to ensure that patients with similar conditions (from the same "cohort") have similar representations, while pushing dissimilar patients further apart in the embedding space.
Experiments and Results
The model was evaluated on two massive, gold-standard real-world datasets: MIMIC-III (data from over 40,000 patients) and MIMIC-IV (updated clinical data from 2008–2019). The researchers focused on six specific disease cohorts for evaluation, including Coronary Atherosclerosis, Septicaemia, and Essential Hypertension.
MHGRL consistently outperformed a wide array of baselines, including specialized EHR models (like GRAM and MiME) and standard GNNs (like GAT and RGCN):
- EHR Clustering: On MIMIC-III, MHGRL achieved a Purity of 0.9761, outperforming the strongest baseline (RGCN) by nearly 3%.
- Disease Prediction: The model showed significant gains in accuracy. On MIMIC-IV, it improved upon the GPS baseline by roughly 3% to 3.7% across different "K" values (the number of similar records retrieved for voting).
- Ablation Success: Removing the multimodal information (text and ontology) caused the most significant drop in performance, proving that external knowledge is the "secret sauce" of this architecture.
Conclusion
MHGRL demonstrates that the relationship between medical entities is as important as the entities themselves. By using a heterogeneous graph and LLM-enhanced textual grounding, the model captures clinical logic that sequence-based models miss. While the current scope focuses on codes and text, future work aims to integrate temporal dynamics and medical imaging to capture the evolving nature of patient health.
Summary updated