PT - JOURNAL ARTICLE AU - Kefeli, Jenna AU - Tatonetti, Nicholas TI - Generalizable and Automated Classification of TNM Stage from Pathology Reports with External Validation AID - 10.1101/2023.06.26.23291912 DP - 2023 Jan 01 TA - medRxiv PG - 2023.06.26.23291912 4099 - http://medrxiv.org/content/early/2023/06/27/2023.06.26.23291912.short 4100 - http://medrxiv.org/content/early/2023/06/27/2023.06.26.23291912.full AB - Cancer staging is an essential clinical attribute informing patient prognosis and clinical trial eligibility. However, it is not routinely recorded in structured electronic health records. Here, we present a generalizable method for the automated classification of TNM stage directly from pathology report text. We train a BERT-based model using publicly available pathology reports across approximately 7,000 patients and 23 cancer types. We explore the use of different model types, with differing input sizes, parameters, and model architectures. Our final model goes beyond term-extraction, inferring TNM stage from context when it is not included in the report text explicitly. As external validation, we test our model on almost 8,000 pathology reports from Columbia University Medical Center, finding that our trained model achieved an AU-ROC of 0.815-0.942. This suggests that our model can be applied broadly to other institutions without additional institution-specific fine-tuning.Competing Interest StatementThe authors have declared no competing interest.Funding StatementNIH NIGMS R35GM131905Author DeclarationsI confirm all relevant ethical guidelines have been followed, and any necessary IRB and/or ethics committee approvals have been obtained.YesThe details of the IRB/oversight body that provided approval or exemption for the research described are given below:The Institutional Review Board associated with Columbia University gave approval for this work.I confirm that all necessary patient/participant consent has been obtained and the appropriate institutional forms have been archived, and that any patient/participant/sample identifiers included were not known to anyone (e.g., hospital staff, patients or participants themselves) outside the research group so cannot be used to identify individuals.YesI understand that all clinical trials and any other prospective interventional studies must be registered with an ICMJE-approved registry, such as ClinicalTrials.gov. I confirm that any such study reported in the manuscript has been registered and the trial registration ID is provided (note: if posting a prospective study registered retrospectively, please provide a statement in the trial ID field explaining why the study was not registered in advance).YesI have followed all appropriate research reporting guidelines, such as any relevant EQUATOR Network research reporting checklist(s) and other pertinent material, if applicable.YesPython scripts used in this study can be found on github. Models generated by this study can be found on Hugging Face. TCGA pathology report text can be found on github. CUIMC pathology reports are not available due to HIPAA compliance. https://github.com/tatonetti-lab/tnm-stage-classifier https://github.com/tatonetti-lab/tcga-path-reports https://huggingface.co/jkefeli/CancerStage_Classifier_T https://huggingface.co/jkefeli/CancerStage_Classifier_N https://huggingface.co/jkefeli/CancerStage_Classifier_M