Miller, Sarah Leanne (2026) Multitask Learning with BERT for Automated Completion of the Breast Cancer Pathology COSD. MPhil thesis, University of Leeds.
Abstract
Breast cancer pathology reporting is crucial for clinical decision-making and national cancer registration in the UK, and it contributes to the Cancer Outcomes and Services Dataset (COSD). Currently, manual extraction of key variables from free-text reports causes data quality issues and delays. This thesis addresses these challenges by developing a novel Multitask BERT (MT-BERT) framework for automated extraction of structured COSD breast pathology attributes. The proposed model combines a BioMedBERT encoder with specialised classification and regression heads to predict seven variables, including histology, grade, and continuous tumour size. To tackle severe class imbalance and missing labels in a real-world dataset of 7673 reports for 2455 breast cancer patients, the model employs a Round-Robin head-balanced sampling method and a sophisticated loss function. This combines Class-Balanced Cross-Entropy with Label-Distribution-Aware Margins (LDAM) and a center Logit Adjustment technique specifically designed for rare histological subtypes. Evaluated on an independent test set, the MT-BERT achieved a mean Macro-F1 score of 0.5566 across all classification tasks, with laterality reaching production-ready accuracy and other variables, including grade, showing promise, though not yet meeting clinical decision-support thresholds. The performance on minority classes in Histology Coded reached a Macro-F1 of 0.5179, partially validating anti-collapse strategies. For the continuous Tumour Size variable, predictions yielded a MAE of 12.23 mm on the original scale. The framework demonstrates that a unified, data-aware multitask transformer can effectively replicate structured COSD reporting, offering a parameter-efficient approach with a single shared encoder in place of seven separate models to support data completeness within the NHS.
Metadata
| Supervisors: | Sharoff, Serge and Hall, Geoffry |
|---|---|
| Keywords: | BERT, NLP, Multitask Learning, Pathology, Breast Cancer |
| Awarding institution: | University of Leeds |
| Academic Units: | The University of Leeds > Faculty of Engineering (Leeds) > School of Computing (Leeds) |
| Date Deposited: | 07 Oct 2026 13:54 |
| Last Modified: | 07 Oct 2026 13:54 |
| Open Archives Initiative ID (OAI ID): | oai:etheses.whiterose.ac.uk:39483 |
You do not need to contact us to get a copy of this thesis. Please use the 'Download' link(s) above to get a copy.
You can contact us about this thesis. If you need to make a general enquiry, please see the Contact us page.