MIPO: Mutual Integration of Patient Journey and Medical Ontology for Healthcare Representation Learning

Xueping Peng, Guodong Long, Tao Shen, Sen Wang, Chengqi Zhang, Allison Clarke, Clement Schlegel · DOI

TL;DR

MIPO (Mutual Integration of Patient Journey and Medical Ontology) is a novel end-to-end Transformer-based framework that harmonizes sequential electronic health record (EHR) data with structured medical knowledge graphs. By training simultaneously on sequential diagnosis prediction and an ontology-based disease-typing task, MIPO creates a mutually reinforcing learning loop that significantly improves prediction accuracy and model interpretability, even under severe data scarcity.

What Problem Does This Paper Address?

Deep learning has shown immense promise in mining Electronic Health Records (EHRs) for predictive healthcare tasks like diagnosis and mortality prediction. However, medical data presents unique challenges: it is highly hierarchical, time-stamped, and frequently plagued by data insufficiency (limited patient cohorts or rare diseases).

To combat data scarcity, recent methods have integrated external medical ontologies (knowledge graphs) to guide representation learning. Yet, existing approaches suffer from two major flaws:

  1. Uniformity and Small Scale of Ontologies: Medical knowledge graphs often contain simple "parent-child" hierarchies that lack the relational diversity needed to train expressively powerful code embeddings on their own.
  2. Neglect of Patient Context: Current models rarely exploit the rich contextual dependencies of an individual's actual "patient journey" (the sequence of clinical visits) to refine the ontology learning process itself.

MIPO addresses these gaps by bridging the patient journey and medical ontology into a unified, interactive architecture.

Methods

Fig. 1: The model architecture of MIPO. The graph is format- ted as a hierarchical tree, in which, the root node is virtual. To construct the tree, the leaf nodes (solid circles) denote fine-grained diagnoses, and the non-leaf nodes (dotted circles) denote coarse-grained disease concepts.

MIPO uses a hierarchical, dual-encoder architecture designed to capture both local (within-visit) and global (across-visits) clinical contexts:

  • Knowledgeable Encoder (V-Encoder): This module fuses basic medical code embeddings with structural node embeddings derived from a medical ontology graph (using a graph-based attention mechanism like GRAM). An information integration layer mixes these heterogeneous features into a united space.
  • Attention Pooling: Medical codes within a single visit are not time-ordered. MIPO uses an attention pooling layer to compress these codes into a single, context-aware visit vector based on their clinical importance.
  • Patient Encoder (P-Encoder): A multi-layer bidirectional Transformer encoder (similar to BERT) processes the sequence of visit vectors to capture long-term temporal dependencies across the patient's entire history.

Dual-Task Learning

The framework is optimized using a joint objective function combining two tasks:

  1. Task-Specific Predictive Task: Predicts the diagnosis codes of the next visit based on the P-Encoder's historical representation.
  2. Ontology-Based Disease Typing Task: A multi-label classification task using the V-Encoder's node embeddings to predict the broader disease categories (from higher levels of the ontology hierarchy) for each medical code.

This dual setup ensures that the patient journey context refines the ontology embeddings, while the ontology structure stabilizes the patient journey representations.

Datasets

The authors evaluated MIPO on two real-world, publicly available benchmark datasets:

  • MIMIC-III: A large-scale dataset containing ICU patient records. The authors selected 7,499 patients with at least two visits, characterized by short visit sequences but highly granular diagnosis codes.
  • eICU Collaborative Research Database: A multi-center ICU database. The authors selected 16,180 patients with at least two visits. Compared to MIMIC-III, it features longer visit records but fewer distinct observed labels, representing a significantly data-insufficient scenario for fine-grained labels.

Key Insights and Ideas

  • The Mutually Reinforcing Loop: Instead of treating the medical knowledge graph as a static lookup table, MIPO dynamically updates code and node representations by passing information back and forth between the patient journey context and the graph structure.
  • Robustness to Small Data: When training data is scarce, standard deep models overfit or fail to converge. MIPO's ontology-based disease typing task acts as a powerful regularizer. It forces the model to anchor its representations to established medical hierarchies, preventing it from overfitting to small sample sizes.

Key Results

Predictive Performance

MIPO consistently outperformed state-of-the-art baselines—including graph-based models (GRAM, KAME), attention-based models (Dipole, RETAIN), and plain RNNs (BRNN)—across both datasets. On the MIMIC dataset, MIPO improved precision by 5.94% over KAME and 5.76% over GRAM (at $k=5$).

Data Sufficiency Analysis

To test robustness, the authors varied the training data size from 20% to 80%. As shown in the evaluation plots, MIPO maintains a substantial performance edge even when trained on just 20% of the data, whereas baseline models experience sharp performance degradation or overfit to the knowledge graph at the expense of sequential context.

Fig. 2: Acc@20 of diagnoses prediction on MIMIC and eICU, size of training data is varied from 20% to 80%.

Interpretability

Using t-SNE to project the learned medical code representations into a 2D space, MIPO demonstrated superior interpretability. It successfully mapped medical codes into 18 distinct, non-overlapping clusters that perfectly align with the official CCS multi-level medical hierarchy. In contrast, baseline methods exhibited significant cluster overlap and mixing.

Fig. 4: t-SNE Scatterplots of Medical Codes Learned by Predictive Models on the MIMIC dataset.

Limitations and Future Work

While MIPO demonstrates strong capabilities in handling hierarchical diagnosis codes, the paper primarily focuses its evaluation on sequential diagnosis prediction and disease typing. The authors note that real-world EHR data contains other critical clinical modalities, such as procedures, medications, and laboratory tests. Future extensions of this work could involve expanding the framework to integrate multi-modal medical ontologies that encompass these diverse clinical events simultaneously.

Summary updated

BibTeX
@inproceedings{peng2025mipo,
  author = {Xueping Peng and Guodong Long and Tao Shen and Sen Wang and Chengqi Zhang and Allison Clarke and Clement Schlegel},
  title = {{MIPO: Mutual Integration of Patient Journey and Medical Ontology for Healthcare Representation Learning}},
  booktitle = {IJCNN},
  year = {2025},
  doi = {10.1109/ijcnn64981.2025.11228235},
}
Figure