DH 2026

Daejeon, July 27–31

Wed, July 2916:30–18:00S091108
Long Paper

Making Textual Heritage Accessible: An Open-Source Text Recognition Framework for Sensitive Data

Nils Hamann
Center for Scalable Data Analytics and Artificial Intelligence (ScaDS.AI) Dresden/Leipzig, Leipzig University, Germany · nils.hamann@uni-leipzig.de
Richard Khulusi
Center for Scalable Data Analytics and Artificial Intelligence (ScaDS.AI) Dresden/Leipzig, Leipzig University, Germany; Leipzig University, Image and Signal Processing Group, Germany; Bergen-Belsen Memorial, Lower Saxony Memorials Foundation, Germany · khulusi@informatik.uni-leipzig.de
Stephanie Billib
Bergen-Belsen Memorial, Lower Saxony Memorials Foundation, Germany · stephanie.billib@stiftung-ng.de
Gerik Scheuermann
Center for Scalable Data Analytics and Artificial Intelligence (ScaDS.AI) Dresden/Leipzig, Leipzig University, Germany; Leipzig University, Image and Signal Processing Group, Germany · scheuermann@informatik.uni-leipzig.de

Figure Textum review interface with a side-by-side view of the editable transcription (left) and the original document (right). Dictionary-based highlighting marks unrecognized words (yellow), while the active transcription line is simultaneously highlighted in the document image (red).

Introduction

Small memorials and archives face a persistent barrier in digitizing historical documents: existing solutions like Transkribus (Kahle et al. 2017) are either too costly, raise data sovereignty concerns, or require technical expertise beyond their capacity. This work discusses the need for an accessible, offline, and cost-free solution for the automatic text recognition of historical documents. Following up on this, we introduce Textum, designed as a free, open-access, offline, and setup-free one-click OCR/HTR solution, tailored for smaller cultural institutions. Developed in close collaboration with the Bergen-Belsen Memorialhttps://www.bergen-belsen.de/, the tool focuses on diaries written by concentration camp prisoners in secret and under extreme conditions (Khulusi et al. 2022). With official documentation deliberately destroyed before liberation, these diaries serve as important sources for reconstructing camp life. Yet, their scholarly potential remains largely unrealized: many exist only as scans or in published editions with restrictive copyright, preventing computational analysis. Making these sources machine-readable enables distant reading approaches, creation of digital editions, and long-term digital preservation. To this end, Textum is maintained as an open-source projecthttps://codeberg.org/textum/app supported by online documentationhttps://textum.codeberg.page/, ensuring it remains a sustainable resource for the community.

Data: Diaries of Concentration Camp Prisoners

Working with primary historical sources is an essential part of a historian's research. One special kind of primary source is a diary. Diaries are ego-documents written by individuals that provide personal experiences and descriptions about themselves and their lives. This includes memories recorded not only with a day-precise timestamp but also with temporal closeness between experiencing and writing.

A special relevance is given to diaries written in non- or only sparsely documented contexts, such as concentration camps. With the intention of keeping the conditions of prisoners secret from the public, events in concentration camps were only internally documented. Towards the end of WWII, many such documents were deliberately destroyed to hide traces of atrocities. For the same reason, writing diaries was strongly prohibited in concentration camps. Still, a noticeable number of diaries were written and preserved. In this paper, we include diaries of the two concentration camps, Kamp Westerborkhttps://kampwesterbork.nl/en/ in the Netherlands and Bergen-Belsen in Germany. Both were classified as transit camps, meaning that prisoners were held before being deported to other camps like Auschwitz or designated to be exchanged for Prisoners-of-War or goods. This also explains the relatively high number of diaries from those camps. The non-official documentation of events in concentration camps was usually forbidden and punished severely. Under usual camp conditions, prisoners had no personal belongings that would even allow them to write diaries or letters. For transit camps – and the undecided fate of prisoners – the Nazis often allowed less harsh (although still inhumane) conditions to prevent reporting of cruel conditions in concentration camps by word of mouth. This included allowing prisoners to keep their luggage, which often contained writing utensils and paper, enabling them to write at least in secret and while hiding the documents.

How many diaries were written (and still exist) is unknown. While institutions like museumshttps://www.ushmm.org/remember, memorials, or research institutionshttps://www.niod.nl/en/about-niod/about-niod are known to hold corpora, some diaries are still in private collections or were lost. The corpus of almost 40 diaries in Bergen-Belsen is considered one of the largest known collections from a single camp. The diaries contain written records from different parts of the camp and across multiple years, allowing historians to trace changes in camp conditions over time. These conditions changed rapidly due to various factors like war developments, camp overcrowding, and resource shortages. The diverse nationalities of prisoners transferred between camps and held in Bergen-Belsen resulted in diaries written in many different languages, posing additional challenges for translation, automated processing, and usability. Written under extreme circumstances, the diaries also present a wide range of physical conditions, some severely damaged. A number of diaries are well-preserved or even transcribed and published, while others only exist digitally as scans of the original manuscripts. This is further complicated by tiny handwriting or the use of abbreviations or encoded words and names due to fear of guards finding and reading the diaries. The nature of diaries – in contrast to testimonies – documenting events in close temporal proximity and with a high level of uncertainty about the situation makes them especially important for historians seeking insights into camp life, the circulation of information among different groups of prisoners, and the evolution of emotions over time. Oral testimonies, while more available, tend to skew this information by both mixing information and feelings gathered over larger timespans and the interviewees knowing they survived the ordeal.

Previous work on concentration camp diaries emphasizes their importance (Schröder 2010). To utilize their potential, the documents need to be available as a digital and machine-readable version, which is mostly given for larger institutions profiting from dedicated digitization projects. Other institutions, like the Bergen-Belsen Memorial or Bernburg Memorialhttps://encyclopedia.ushmm.org/content/en/article/bernburg-t4-facility. Accessed 8th December 2025., hold important documents waiting for ways of processing without the barriers imposed by current solutions.

Existing Solutions and Limitations

Current text recognition solutions present fundamental barriers for small institutions. Transkribus and other cloud services (Google Document AIhttps://cloud.google.com/document-ai, Azure Document Intelligencehttps://azure.microsoft.com/products/ai-foundry/tools/document-intelligence) are commercial platforms that require ongoing subscriptions, raise data sovereignty concerns for sensitive Holocaust materials, and retain rights to use uploaded data for model improvement. While Transkribus offers on-premise installations, these remain costly for smaller memorials. Free and open-source alternatives introduce different challenges, with a few examples being:

These solutions assume IT infrastructure, employees, and knowledge or experience that is often not available or affordable for smaller cultural institutions (Nikolaou 2024, Pandey / Kumar 2020).

Digitization Solution

Figure Overview of Textum’s text recognition pipeline. The system preprocesses input images before branching into two specialized pipelines: printed documents are handled by KOSMOS-2.5 with page-level recognition, while handwritten documents undergo stroke enhancement, YOLO-based line segmentation, and TrOCR line-level recognition. Both branches converge to a unified JSON format for post-processing, word validation, review, and export in multiple formats.

Textum integrates transformer-based computer vision models into a user-friendly workflow. Designed as a portable, standalone program requiring no technical expertise and no installation of runtimes or frameworks, the application can be run immediately after downloading. This seamless distribution model is enabled by Nuitkahttps://nuitka.net/. Textum operates fully offline, ensuring compliance with data protection standards through local processing – critical when handling sensitive archival materials. The application supports multiple input formats (single images, PDFs, directories) with optional double-page splitting and orientation correction. Processing runs are handled asynchronously, with configurable concurrency limits. Furthermore, it implements two specialized recognition pipelines. For printed texts, KOSMOS-2.5 performs document-level OCR, simultaneously recognizing text and layout structure (Lv et al. 2024). For handwritten documents, a more complex pipeline combines YOLO-based line segmentation with a TrOCR model fine-tuned specifically on in-domain historical diary pages (Redmon et al. 2016, Li et al. 2023).

In general, this paper’s main contribution lies explicitly in providing an easy-to-use, free, and open-source text recognition framework. While the tool is pre-configured with models for both OCR and HTR, its modular design enables users to integrate their own specialized models as needed.

HTR-Training using a small dataset

The TrOCR handwriting model was fine-tuned on 105 diary pages (2,758 lines) from the concentration camps Bergen-Belsen and Westerbork, including Dutch (62%) and German (38%) texts. This small-scale, domain-specific approach demonstrates that institutions do not need to access massive datasets to achieve functional HTR. Through systematic experimentation, we identified optimal training configurations: pretraining the decoder on ground-truth texts (decoder warm-up) combined with unfreezing the final eight encoder layers proved most effective, yielding 46.4% relative improvement over baseline configurations. The best model achieved a 14.12% Character Error Rate (CER) on held-out test pages, with similar performance across both languages (Dutch: 14.05%, German: 14.25%). However, we offer this model only as a first handwriting model to test out the tool.

Review Workflow

The review interface forms the core of Textum's workflow, designed around the principle that quality assurance requires human verification regardless of automated accuracy. The interface displays original images alongside editable transcriptions in a side-by-side layout (see Figure 1). Unrecognized words, identified through comparison with multilingual dictionaries, are automatically highlighted, enabling efficient error detection. Crucially, the system marks – but never automatically corrects – unknown terms, preserving historical orthography and camp-specific jargon.

Results

For the printed documents (OCR), we evaluated available open-weight models for integration into the application. The test set comprised 15 scans of printed Holocaust diaries from the Bergen-Belsen archives10 German pages, 3 Hungarian, 2 French.. KOSMOS-2.5 achieved a 3.4% average CER, with exceptional performance on German documents (0.9% CER). Qwen2.5-VL-72B reached 1.7% CER, DocTR (5.5%), Tesseract (8.3%), with others exhibiting a higher CER. KOSMOS was selected for its combination of efficient local executability and strong performance on Latin script, despite slightly trailing Qwen's overall accuracy. Furthermore, KOSMOS’ OCR mode includes bounding boxes and has a deterministic format, eliminating the output variability of general-purpose vision models, such as Qwen.

For handwriting, the fine-tuned TrOCR model achieved 14.12% CER (see above). Transkribus reports 3-5% CER for its Germanhttps://app.transkribus.org/models/text/german-genius-super-model. Accessed 9th December 2025. and Dutchhttps://app.transkribus.org/models/text/dutch-dean-super-model. Accessed 9th December 2025. models, though an in-domain evaluation on the Bergen-Belsen pages was not performed. This prototype primarily demonstrates the workflow's functionality and enables the integration of higher-performing handwriting models in the future.

For the application itself, user testing with historians of the Bergen-Belsen Memorial confirmed usability: they noted the intuitive interface, automatic highlighting of uncertain words, and offline capability as valuable. After the positive guided session, the memorial has already started integrating Textum for ongoing digitization work.

Current limitations include the small handwriting training corpus and restricted generalization of the YOLO line segmentation models, which were trained on historical Swedish manuscriptshttps://huggingface.co/Riksarkivet/yolov9-lines-within-regions-1. Accessed 11th December 2025.. However, the modular architecture enables future extensions: expanding training datasets, developing domain-specific segmentation models, and enabling alternative recognition backends could address these constraints while preserving ease of use for non-technical users.

Conclusion

Developed in collaboration with the Bergen-Belsen Memorial, Textum demonstrates that advanced text recognition can be made accessible to institutions without technical expertise or substantial funding. By providing a simple, offline application for digitizing sensitive historical documents, it removes barriers that previously prevented smaller archives and memorials from processing their collections independently. While the tool handles printed materials directly, handwritten documents from other domains require additional training on relevant corpora. Nevertheless, Textum democratizes digitization technologies for cultural institutions of all sizes.

Acknowledgements

The authors acknowledge the financial support by the Federal Ministry of Research, Technology and Space of Germany and by Sächsische Staatsministerium für Wissenschaft, Kultur und Tourismus in the programme Center of Excellence for AI-research “Center for Scalable Data Analytics and Artificial Intelligence Dresden/Leipzig”, project identification number: ScaDS.AI.

References
  1. Kahle, Philip / Colutto, Sebastian / Hackl, Günter / Mühlberger, Günter (2017): “Transkribus - A Service Platform for Transcription, Recognition and Retrieval of Historical Documents”, in: 2017 14th IAPR International Conference on Document Analysis and Recognition (ICDAR). Kyoto: IEEE. 19–24. 10.1109/ICDAR.2017.307.
  2. Khulusi, Richard / Billib, Stephanie / Jänicke, Stefan (2022): “Exploring Life in Concentration Camps through a Visual Analysis of Prisoners’ Diaries”, in: Information 13 (2): 54. 10.3390/info13020054.
  3. Kiessling, Benjamin / Tissot, Robin / Stokes, Peter / Stokl Ben Ezra, Daniel (2019): “eScriptorium: An Open Source Platform for Historical Document Analysis”, in: 2019 International Conference on Document Analysis and Recognition Workshops (ICDARW). Sydney, Australia: IEEE. 19–19. 10.1109/ICDARW.2019.10032.
  4. Li, Minghao et al. (2023): “TrOCR: Transformer-Based Optical Character Recognition with Pre-trained Models”, in: Proceedings of the AAAI Conference on Artificial Intelligence 37 (11): 13094–13102. 10.1609/aaai.v37i11.26538.
  5. Lv, Tengchao et al. (2024): “KOSMOS-2.5: A Multimodal Literate Model”. arXiv:2309.11419 [11 Sep 2025].
  6. Neudecker, Clemens / Baierer, Konstantin / Federbusch, Maria / Boenig, Matthias / Würzner, Kay-Michael / Hartmann, Volker / Herrmann, Elisa (2019): “OCR-D: An end-to-end open source OCR framework for historical printed documents”, in: Proceedings of the 3rd International Conference on Digital Access to Textual Cultural Heritage. Brussels Belgium: ACM. 53–58. 10.1145/3322905.3322917.
  7. Nikolaou, Polina (2024): “Museums and the Post-Digital: Revisiting Challenges in the Digital Transformation of Museums”, in: Heritage 7 (3): 1784–1800. 10.3390/heritage7030084.
  8. Pandey, Rahul / Kumar, Vinit (2020): “Exploring the Impediments to Digitization and Digital Preservation of Cultural Heritage Resources: A Selective Review”, in: Preservation, Digital Technology & Culture 49 (1): 26–37. 10.1515/pdtc-2020-0006.
  9. Redmon, Joseph / Divvala, Santosh / Girshick, Ross / Farhadi, Ali (2016): “You Only Look Once: Unified, Real-Time Object Detection”, in: 2016 IEEE Conference on Computer Vision and Pattern Recognition (CVPR). Las Vegas, USA: IEEE. 779–788. 10.1109/CVPR.2016.91.
  10. Reul, Christian et al. (2019): “OCR4all—An Open-Source Tool Providing a (Semi-)Automatic OCR Workflow for Historical Printings”, in: Applied Sciences 9 (22): 4853. 10.3390/app9224853.
  11. Schröder, Dominique (2010): “Semantics of the self. Preservation and construction of identity in concentration camp diaries”, in: InterDisciplines. Journal of History and Sociology 2: 10.2390/INDI-V1-I2-20.