Revised: March 11, 2026
Accepted: April 20, 2026
Published online: June 27, 2026
Processing time: 155 Days and 15 Hours
Noninvasive assessment of liver fibrosis is essential for the management of chronic hepatitis B (CHB), but existing tools have important limitations. Liver biopsy is invasive and unsuitable for repeated use, while commonly used serum indices show variable performance across populations and elastography is not universally available. We hypothesized that a laboratory-based machine-learning model using routinely available tests could provide consistent discrimination across independent clinical settings.
To develop and externally validate a laboratory-based machine-learning model for identifying significant liver fibrosis in CHB.
This multicenter cohort study included adults with CHB who underwent liver biopsy in two tertiary hospitals as a development cohort and one independent tertiary hospital as an external validation cohort. A population-based cohort from the National Health and Nutrition Examination Survey was used for exploratory evaluation with surrogate fibrosis labels. After rule-based harmonization, a stacking ensemble model was trained using routine laboratory variables and evaluated using discrimination, calibration, and decision curve analyses.
The model demonstrated good discrimination in the development cohort [area under the curve (AUC) = 0.853] and in the biopsy-confirmed external cohort (0.838), with acceptable calibration in both. Compared with aspartate aminotransferase to platelet ratio index and fibrosis-4 (FIB-4), the model showed comparable discrimination and similar net clinical benefit across clinically relevant thresholds. Within the FIB-4 indeterminate zone, the model achieved an AUC of 0.821 and reclassified 69.8% of patients into lower- or higher-risk categories with a gradient in observed fibrosis prevalence. In the population-based cohort with aspartate aminotransferase to platelet ratio index/FIB-4-based surrogate labeling, the model preserved risk ranking (AUC 0.817).
A routine laboratory-based machine-learning model provides stable discrimination for significant fibrosis in CHB across clinical settings, with explainability supported by feature attribution analysis.
Core Tip: In this study, a laboratory-based machine-learning model was developed and externally validated for noninvasive identification of significant fibrosis in patients with chronic hepatitis B using biopsy-confirmed multicenter cohorts. The model showed stable discrimination and acceptable calibration across independent hospitals, and retained risk-ranking ability in an exploratory population-based cohort with surrogate fibrosis labels. Because it relies only on routinely available laboratory tests, this model may serve as a practical complementary tool for fibrosis risk stratification, particularly in settings where elastography is unavailable or inconsistently applied.