Temporal Entailment Pretraining for Clinical Language Models over EHR Data
Tatsunori Tanaka, Fi Zheng, Kai Sato, Zhifeng Li, Yuanyun Zhang, Shi Li
TL;DR
Electronic health records are highly temporally structured, and standard MLM pretraining fails to capture causal progression across time. Temporal Entailment Pretraining (TEP) constructs temporally ordered pairs $(x_t, x_{t'})$ with $t < t'$ and predicts $y \in \{\text{entail},\text{contradict},\text{neutral}\}$ using weak supervision, RoPE time encoding, and a bi-sequence Transformer. Pretraining on ~500k patients from MIMIC-IV yields ~3.2M pairs, enabling scalable temporal reasoning that improves temporal QA, early warning, and disease progression modeling, with robust temporal calibration. The results suggest temporality should be a core pretraining signal, enabling more generalizable and temporally coherent clinical NLP models for forecasting and decision support.
Abstract
Clinical language models have achieved strong performance on downstream tasks by pretraining on domain specific corpora such as discharge summaries and medical notes. However, most approaches treat the electronic health record as a static document, neglecting the temporally-evolving and causally entwined nature of patient trajectories. In this paper, we introduce a novel temporal entailment pretraining objective for language models in the clinical domain. Our method formulates EHR segments as temporally ordered sentence pairs and trains the model to determine whether a later state is entailed by, contradictory to, or neutral with respect to an earlier state. Through this temporally structured pretraining task, models learn to perform latent clinical reasoning over time, improving their ability to generalize across forecasting and diagnosis tasks. We pretrain on a large corpus derived from MIMIC IV and demonstrate state of the art results on temporal clinical QA, early warning prediction, and disease progression modeling.
