Explainable Transformer Models for Clinical Prediction Tasks on Structured Electronic Health Records

Jun Ni Du, Lukas Adamek, Maxim Kryukov, Flavio Dormont, Ziv Bar-Joseph +2 more
8/20/2026
cs.LG
transformer-attention

No confident code implementation found for this paper.

Abstract

Predictive models over structured electronic health records (EHRs) remain central to machine learning for healthcare, but few have jointly emphasized quantitative laboratory information and interpretability with respect to input medical events. We present BERT-LER, a BERT-style model for coded EHR timelines pretrained and fine-tuned from a de-identified EHR dataset of 75 million patients, that encodes laboratory test results as discrete tokens while retaining graded information through percentile-based binning, paired with Integrated Gradients for token-level attributions grounded in the input EHR sequence.

Show full abstract

We benchmark our approach on the public EHRShot benchmark suite and on an asthma severity progression study based on real-world data. This addresses a methodological gap in EHR foundation-style modeling by unifying laboratory value representation and explainability in a single framework, while assessing whether both predictive performance and explanations generalize beyond standard clinical prediction tasks. Across EHRShot and asthma tasks, BERT-LER achieves predictive performance that is competitive with, and on laboratory-related tasks often exceeds, publicly available benchmark models, and provides attributions that align with clinically known risk factors. Our architecture and explainability approach can be applied to many therapeutic areas and prediction tasks using language models trained on structured EHRs.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{du2026explainable,
  title  = {Explainable Transformer Models for Clinical Prediction Tasks on Structured Electronic Health Records},
  author = {Jun Ni Du and Lukas Adamek and Maxim Kryukov and Flavio Dormont and Ziv Bar-Joseph and Sven Jager and Brandon Rufino},
  year   = {2026},
  eprint = {2608.20315},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2608.20315v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2608.20315.svg)](https://codeofpaper.com/paper/2608.20315)

Discussion