WSI-Babel-Shark: A modular pipeline for robust metadata extraction from heterogeneous whole slide image labels in digital pathology.
Shahram Aliyari, Maximilian Legnar, Christoph Blattgerste, Ayk Jessen, Balamurugan Thirukonda Subramanian Balakrishnan, Nils Englert, Philip S J Kaib, Mark Sementsov,
Section Computational Pathology Heidelberg, Institute of Pathology Heidelberg, University Hospital Heidelberg, University of Heidelberg, Heidelberg, Germany.
Key points
From the paper's conclusion- WSI-Babel-Shark advances automated metadata extraction from WSIs by introducing a label-layout classification framework validated on heterogeneous label layouts and incorporating open-set recognition, together with standardized ROI annotation and a fully containerized implementation. The framework ensures reproducible linkage between digitized slides and lab information, is designed to facilitate interoperability with lab information systems, and provides a scalable foundation for large-scale digital pathology workflows. The complete implementation is openly available at: https://github.com/cpheidelberg/WSI-Babel-Shark.
Abstract
INTRODUCTION: Automated extraction of slide metadata remains a major bottleneck in digital pathology, especially in settings where barcode identifiers are missing, damaged, or inconsistent. Manual transcription of case, block, and stain information is error-prone and does not scale. Building on our previous whole-slide image (WSI)-Babel-Fish framework, we developed WSI-Babel-Shark, a more extensible pipeline for reliable metadata extraction across heterogeneous slide-label layouts. MATERIALS AND METHODS: WSI-Babel-Shark integrates data matrix code decoding, region of interest (ROI)-based optical character recognition (OCR), and rule-based metadata parsing within a modular Python and Docker architecture. To handle diverse institutional label formats, the system incorporates a deep learning-based label layout classifier using a ResNet-18 backbone, fused with handcrafted descriptors and prototype-based open-set recognition to categorize labels into 10 predefined layout groups. A graphical interface supports ROI annotation, dataset management, and configuration editing. Performance was evaluated on 270 WSIs (.svs and .ndpi formats) and cross-validated using 110 slides from the previously published WSI-Babel-Fish dataset to assess backward compatibility. RESULTS: The label layout classifier achieved an overall accuracy of 97.4%, with macro-averaged precision, recall, and F1-score of 0.98 while reliably rejecting previously unseen layouts. End-to-end pipeline evaluation achieved complete SlideID reconstruction for 258 of 267 evaluable WSIs (96.6%). Independent comparison of OCR-derived metadata with the corresponding Data Matrix-decoded metadata on 236 slides demonstrated complete metadata concordance for 230 slides (97.5%), whereas field-level concordance ranged from 98.3% to 100.0% across all evaluated metadata fields. Cross-dataset analysis confirmed full compatibility with WSI-Babel-Fish label structures. CONCLUSION: WSI-Babel-Shark advances automated metadata extraction from WSIs by introducing a label-layout classification framework validated on heterogeneous label layouts and incorporating open-set recognition, together with standardized ROI annotation and a fully containerized implementation. The framework ensures reproducible linkage between digitized slides and lab information, is designed to facilitate interoperability with lab information systems, and provides a scalable foundation for large-scale digital pathology workflows. The complete implementation is openly available at: https://github.com/cpheidelberg/WSI-Babel-Shark.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- A multimodal knowledge-enhanced whole-slide pathology foundation modelNature Communications · 2025
- LazySlide: accessible and interoperable whole-slide image analysisNature Methods · 2026
- Towards Scalable Diagnostic-Driven Whole-Slide Image Retrieval for Pathology ArchivesarXiv · 2026
- SlideChat is a multimodal generative artificial intelligence assistant for whole-slide computational pathology across cancer types.Nature cancer · 2026
- Pathology foundation models for training-free case retrieval in salivary gland tumorsarXiv · 2026
- ALPaCA: Adapting Llama for Pathology Context Analysis to enable slide-level question answering.Nature communications · 2026