Immune checkpoint inhibitors (ICIs) have reshaped treatment for advanced hepatocellular carcinoma (HCC), with the atezolizumab plus bevacizumab combination widely adopted as a first-line option. Alongside efficacy gains, immune-related adverse events (irAEs) pose significant clinical challenges because they can affect multiple organ systems and often lead to treatment interruption, systemic immunosuppression, or discontinuation. Early-onset clinically significant irAEs (grade ≥2) within the initial treatment period are particularly important because they commonly require active intervention and can disrupt early therapeutic continuity.
Existing risk-assessment approaches have been limited by focus on post-treatment biomarkers, single variables, or mixed early/late irAE endpoints. The authors aimed to develop and externally validate an interpretable deep learning model to enable pre-treatment prediction of early clinically significant irAEs in HCC patients receiving Atezo+Bev. The goal was to combine routinely available clinical, laboratory, and immunological baseline markers to balance predictive accuracy, generalizability, and interpretability.
This study was a multicenter retrospective cohort study. From an initial screening of 741 patients treated between May 2020 and December 2023, patients were allocated to a training cohort and an independent external validation cohort according to treatment hospital. The final training cohort comprised 453 patients from Harbin Medical University Cancer Hospital and included 141 early clinically significant irAE events. The external validation cohort comprised 201 patients pooled from two centers (Sixth Affiliated Hospital of Harbin Medical University and the People’s Hospital of Dazu District, Chongqing) with a combined total of 59 early clinically significant irAE events. Cohorts were separated at the hospital level with no patient overlap. Thirteen patients were excluded for missing prespecified key baseline variables.
Inclusion criteria required age ≥18 years, confirmed HCC, and receipt of at least one complete Atezo+Bev treatment cycle. Exclusion criteria included concurrent primary malignancy, prior liver transplantation or severe autoimmune disease, missing prespecified baseline predictors, incomplete follow-up or indeterminate early irAE outcome within the 3-month window, and active infection at baseline requiring systemic antibiotics.
All patients received atezolizumab (1200 mg IV) plus bevacizumab (15 mg/kg IV) every 3 weeks. The study focused on early events within a prespecified 3-month observation window after the first ICI dose. The outcome was occurrence of at least one CTCAE v5.0 grade ≥2 irAE within that window. IrAE ascertainment used systematic medical-record review and a clinician adjudication panel; events judged more plausibly non–immune-related (for example, hepatic decompensation, infection, progression, or bevacizumab-specific toxicity) were excluded from irAE classification. Descriptive irAE characteristics (organ system, grade, time to onset, glucocorticoid use, treatment interruption, permanent discontinuation) were extracted for profiling but were not used as model predictors.
A prespecified set of 51 baseline predictors was selected to capture host immune status, organ functional reserve, and routine clinical features. Predictors included demographics and clinical variables (age, BMI, sex, smoking, drinking, Child–Pugh class, ABO type, prior surgery, tumor number and size, cirrhosis, BCLC stage), immunological markers (serum IgA, IgG, IgM; proportions of CD3+, CD4+, CD8+ T cells; CD4+/CD8+ ratio; CD19+ B cells; NK-cell subsets), routine laboratories (ALT, AST, γ-GGT, LDH, bilirubin fractions, total protein, albumin, globulin, A/G ratio, prealbumin, renal tests, glucose, blood counts including platelet count), and coagulation markers (INR, fibrinogen, D-dimer).
All baseline values were recorded within 7 days prior to therapy; continuous variables were kept on original scales and standardized as required. Only complete-case patients with full prespecified baseline data were included; no data imputation was performed.
Five prediction algorithms were developed in parallel using the identical predictor set: TabNet, logistic regression, random forest, XGBoost, and support vector machine. Models were trained exclusively in the training cohort, with hyperparameter tuning performed using stratified 5-fold cross-validation and area under the ROC curve (AUC) as the tuning metric. Preprocessing steps (standardization, encoding) were fit within each training fold to avoid information leakage. Logistic regression collinearity was assessed with tolerance and variance inflation factor. Final model evaluation occurred in an independent external validation cohort; no validation data were used during training or tuning.
Model performance assessment included discrimination, calibration, and clinical utility metrics. Interpretability was addressed using feature-attribution analyses to identify contributors to model-predicted risk. Additional analyses included risk-stratified feature clustering to explore patterns among predictive features.
After applying eligibility criteria and excluding patients with missing prespecified predictors, the training cohort included 453 patients with 141 early clinically significant irAE events. The external validation cohort included 201 patients with 59 early clinically significant irAE events. The same inclusion/exclusion criteria and adjudication process were applied across centers, and follow-up was censored at March 21, 2024.
Across the five candidate algorithms, the TabNet model demonstrated the most favorable overall performance profile, considering discrimination, calibration, clinical utility, and external validation results. Calibration analysis indicated good agreement between predicted risks and observed early irAE rates. Decision curve analysis and clinical impact assessment suggested meaningful clinical utility across a range of threshold probabilities, supporting potential usefulness for pre-treatment risk stratification.
Interpretability and feature-attribution analyses highlighted several baseline variables as principal contributors to predicted early irAE risk: the CD4/CD8 ratio, serum IgG level, albumin, platelet count, and the proportion of CD19-positive B cells. Risk-stratified feature clustering further suggested that immune-related markers and measures of host functional reserve may represent complementary dimensions associated with early immune-toxicity risk.
The TabNet model’s calibration showed close correspondence between predicted probabilities and observed event frequencies in the external cohort. Decision curve analysis and clinical impact assessment indicated that using the model could provide net clinical benefit across various threshold probabilities relevant for clinical decision-making about monitoring intensity and early intervention strategies.
This study developed and externally validated an interpretable deep learning model for pre-treatment prediction of early clinically significant irAEs in HCC patients receiving Atezo+Bev. By integrating routinely available baseline immunological and clinical markers, the model aims to support prospective risk stratification at treatment initiation. Interpretability analyses identified intuitive biological contributors—T-cell balance, humoral immunoglobulin levels, B-cell proportion, and markers of host functional reserve—that align with current understanding of immune vulnerability to checkpoint blockade.
Limitations include the retrospective design, complete-case analytic strategy, and the fact that predictors and outcomes were derived from the participating centers’ clinical practice. The authors reported no imputation and used predefined predictors; further prospective validation and assessment of clinical implementation workflows would be needed before routine use.
An interpretable TabNet deep learning model using 51 prespecified baseline clinical and immunological variables was developed and externally validated to predict early grade ≥2 immune-related adverse events in patients with hepatocellular carcinoma treated with atezolizumab plus bevacizumab. Key contributors to predicted risk included the CD4/CD8 ratio, IgG, albumin, platelet count, and CD19-positive B cells, suggesting complementary roles of immune profile and host reserve in early irAE susceptibility. The model demonstrated favorable discrimination, calibration, and potential clinical utility in external validation.