Patient Trajectories as Clinical Language Modeling

This direction is merged into another direction: multimodal clinical data integration. Its last version stays readable and citable here.

Version 1 of 118 papers20 conceptsfrozen 2026-10-04

Traditionally, electronic health records (EHRs) were treated as static snapshots—tabular data where a patient's risk was calculated from a fixed set of features. However, a new research direction reframes a patient’s medical history as a longitudinal narrative. By treating discrete medical codes (diagnoses, procedures, and medications) as "words" and a patient’s timeline as a "sentence," researchers are applying the machinery of natural language processing to predict the future of human health.

The Patient as a Sequence

The core intuition behind this shift is that disease progression has a "syntax." Just as certain words are likely to follow others in a sentence, medical events follow patterns dictated by biology and clinical practice. Phuoc Nguyen and Truyen Tran pioneered this view with Deepr, using Convolutional Neural Networks to detect "clinical motifs"—recurring sequences of events that signal high risk, such as a specific sequence of symptoms leading to an unplanned readmission.

In this framework, the EHR is no longer a database to be queried, but a stream of discrete tokens. This allows models to capture the temporal dependencies that static models miss: the order of treatments matters as much as the treatments themselves.

From Motifs to Transformers

As the field moved from CNNs to Transformers, the "EHR-as-language" metaphor deepened. Models like BEHRT, evaluated by Yusuf Yildiz and colleagues on the UK Biobank, use self-attention to weigh the importance of every past medical event against every other event.

This architecture solves a fundamental clinical problem: relevance. A diagnosis from ten years ago might be irrelevant for a broken leg, but critical for a chronic heart condition. Transformers learn these dependencies automatically through masked language modeling—predicting missing medical codes in a patient's history to learn the underlying "semantics" of disease. This pre-training on large-scale unlabeled records, as explored in Multi-TA, allows models to understand complex patient trajectories before they are ever tasked with a specific prediction.

Scaling the Context Window

A major hurdle in clinical sequence modeling is the "long-context" problem. A patient with a chronic illness may have thousands of interactions over decades. Standard Transformers struggle with these extremely long sequences due to the quadratic cost of attention.

To address this, Michael Wornow, Christopher Ré, and their team at Stanford utilized subquadratic architectures like Mamba in their Context Clues study. By scaling the context window to 16,000 tokens, they demonstrated that "remembering" the entirety of a patient's history—rather than just the most recent visits—significantly improves the accuracy of clinical predictions.

Generative Health Outcomes

If a patient's history is a sentence, then the future is simply the next word. This realization has led to generative foundation models for healthcare. Pawel Renc and colleagues developed ETHOS, which treats health outcome simulation as a zero-shot generation task. Instead of training a specific model for mortality and another for readmission, a single generative model can "predict" the next likely medical events in a trajectory.

This generative approach also solves the data scarcity and privacy problem. Chao Pang and the creators of CEHR-GPT use GPT-style architectures to synthesize realistic, chronological EHRs. By learning the statistical patterns of real patient journeys, these models can generate synthetic cohorts that preserve clinical utility for research without exposing sensitive individual data.

Beyond Prediction: Reasoning and Trajectories

The shift toward sequence modeling is also changing how we approach diagnosis. Junying Chen and the authors of Diaformer argue that diagnosis is not a single classification but a sequence of symptoms and inquiries. By framing diagnosis as a sequence generation task, they mimic the iterative reasoning of a physician.

Ultimately, this research direction aims for proactive medicine. Models like ForeSITE, developed by Lu Yang and Elliot Bolton, map "multimorbidity trajectories." By treating the onset of chronic diseases as a sequential language task, these models can forecast not just if a patient will get sick, but when and in what order, moving healthcare from reactive treatment to personalized, longitudinal prevention.

Papers in this version

History & citationVersion 1 · 2026-10-04

Merged into another direction · Permanent link

View frozen version 1

Cite this direction

Latest version (a living page):

@misc{lacuna_patient_trajectories_as_clinical_languag_ede9ef4d,
  title = {Patient Trajectories as Clinical Language Modeling},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/patient-trajectories-as-clinical-language-modeling/rdr_ede9ef4d2eb04246b97401cd69317402},
  note = {Latest version of a living research direction; cite a version for a fixed text. Accessed 2026-11-27},
}

This exact version (version 1, frozen text):

@misc{lacuna_patient_trajectories_as_clinical_languag_ede9ef4d_v1,
  title = {Patient Trajectories as Clinical Language Modeling},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/patient-trajectories-as-clinical-language-modeling/rdr_ede9ef4d2eb04246b97401cd69317402/v/1},
  note = {Version 1, frozen 2026-10-04. Accessed 2026-11-27},
}