LLM-based reconstruction of longitudinal clinical trajectories in chronic liver disease

Abstract Liver cancer primarily develops in patients with chronic liver disease (CLD), yet most cases are diagnosed at advanced stages with poor prognosis. While CLD surveillance generates extensive longitudinal data, its free-text nature hinders large-scale research. To address this, we developed a scalable framework using open-source LLMs with constrained decoding to process unstructured text across radiology, pathology, and transplant assessment domains. A calibration set comprising 507 reports from 30 patients was manually annotated to benchmark four LLMs against a regular expression baseline across 70 tasks. Llama-3.3-70B performed best, exceeding 90% accuracy on 59/70 tasks, outperforming Llama-3.1-8B (a smaller variant), OpenBioLLM-70B (a medically fine-tuned model), and DeepSeek-R1-8B. Constrained decoding achieved > 99.9% format adherence, far surpassing unconstrained prompting (87.4%). Applied to the full cohort, the pipeline analysed 22,493 reports to generate a patient-level database of 29,225 datapoints (35 variables, 835 patients) without manual annotation. Further analysis confirmed known liver cancer risk factors (male sex, viral hepatitis, smoking, diabetes), and allowed for reconstruction of individualised disease timelines. This work provides a scalable blueprint for transforming real-world clinical free-text into structured formats and personalised patient trajectories. Future applications have the potential to accelerate data-driven research into early cancer detection within complex pre-cancerous diseases like CLD.

Authors

Publication Details

Journal
npj Precision Oncology
Published
2026-09-30
DOI
https://doi.org/10.1038/s41698-026-01650-4
Primary Topic
Machine Learning in Healthcare
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
article

LLM-based reconstruction of longitudinal clinical trajectories in chronic liver disease

Mireia Crispin‐Ortuzar, Matthew Hoare, Hania Paverd, Margarete Fabre et al.
npj Precision Oncology
Machine Learning in Healthcare
article

LLM-based reconstruction of longitudinal clinical trajectories in chronic liver disease

Mireia Crispin‐Ortuzar, Matthew Hoare, Hania Paverd, Margarete Fabre, Golnar Mahani, Sarah Burge, Zeyu Gao
article en

Abstract

Abstract Liver cancer primarily develops in patients with chronic liver disease (CLD), yet most cases are diagnosed at advanced stages with poor prognosis. While CLD surveillance generates extensive longitudinal data, its free-text nature hinders large-scale research. To address this, we developed a scalable framework using open-source LLMs with constrained decoding to process unstructured text across radiology, pathology, and transplant assessment domains. A calibration set comprising 507 reports from 30 patients was manually annotated to benchmark four LLMs against a regular expression baseline across 70 tasks. Llama-3.3-70B performed best, exceeding 90% accuracy on 59/70 tasks, outperforming Llama-3.1-8B (a smaller variant), OpenBioLLM-70B (a medically fine-tuned model), and DeepSeek-R1-8B. Constrained decoding achieved > 99.9% format adherence, far surpassing unconstrained prompting (87.4%). Applied to the full cohort, the pipeline analysed 22,493 reports to generate a patient-level database of 29,225 datapoints (35 variables, 835 patients) without manual annotation. Further analysis confirmed known liver cancer risk factors (male sex, viral hepatitis, smoking, diabetes), and allowed for reconstruction of individualised disease timelines. This work provides a scalable blueprint for transforming real-world clinical free-text into structured formats and personalised patient trajectories. Future applications have the potential to accelerate data-driven research into early cancer detection within complex pre-cancerous diseases like CLD.

npj Precision Oncology
Good health and well-being
Openalex Percentile: Top 9%
Machine Learning in Healthcare
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.