Rediscover Pretrained Models & Historical Lexicons

Pretrained lightweight CPU ONNX models, zero-leakage historical lexicons / bigram language models, and commercial-compatible fine-tuned Kraken HTR specialist weights for Rediscover.

Note on NonCommercial Models: Fine-tuned models derived from NonCommercial sources are hosted separately so that every artifact in this repository remains 100% compatible with commercial and open-source use under Apache-2.0, CC-BY-4.0, CC-BY-SA-4.0, or CC-BY-2.0:


Quick Download (via Rediscover CLI)

git clone https://github.com/Flokey82/rediscover.git
cd rediscover
pip install -e ".[ocr]"

# 1. Download ONNX models + zero-leakage historical lexicons (~11.6 MB bundle):
python scripts/setup_reproduce.py --download-assets --check

# 2. Download fine-tuned Kraken .mlmodel weights into ~/kraken-models (or any folder):
python scripts/setup_reproduce.py --download-kraken-models --kraken-dest ~/kraken-models

Zero-Leakage Benchmark Scorecards

All evaluations below use strictly disjoint held-out manuscript folios (data/eval/packs/* in the Rediscover repository) with zero train/eval manuscript or scribe overlap.

1. Fine-Tuned Kraken HTR Specialists (kraken/)

Model Status License Held-Out Eval Pack Stock Baseline (tri_f1 / skel_CER) Fine-Tuned Raw Kraken (tri_f1 / skel_CER) Full Escalation / Hybrid (tri_f1 / Word P/R) GT Word Hits vs. Stock
western_early_modern_ft.mlmodel (16th-c. Western Humanist Latin — Bullinger/Gwalther) Tier-1 PRODUCTION_READY (16th-c. Humanist specialist) CC-BY-4.0 gold12_western_em_gwalther (N=12) 0.505 / 28.9% (stock McCATMuS V1) 0.917 ± 0.014 (med 0.920, +0.412) / 5.3% (-23.6pp) 83.3% / 84.3% (raw, 0/12 low-cert, ρ = 0.818, 14.4s/p) 1,489 vs 368 (4.05×)
greek_byz_ren_ft.mlmodel (14th–16th c. Byzantine & Renaissance Greek) Tier-1 PRODUCTION_READY CC-BY-SA-4.0 gold12_greek_byz_ren (N=12) 0.705 / 17.8% (stock PTA) 0.902 ± 0.021 (+0.197) / 6.9% (-10.9pp) 67.6% / 68.6% (raw, 0/12 low-cert, 13.9s/p) 661 vs 436 (+51.6%)
syriac_codex_ft.mlmodel (v2 — Classical Syriac Serto + 6th–12th c. Estrangelo) PRODUCTION_READY CC-BY-4.0 gold24_syriac_serto_estrangelo (N=24: 12 Serto + 12 Estrangelo) + wild 551 CE Vat.sir.112 v1: 0.556 (1,218 hits); stock Sophro Mhiro: 0.690 (2,621 hits) 0.759 (27.7% Serto CER; 0.750 12th-c. Estrangelo; 76.4% lex3 on 551 CE Vat.sir.112) Serto + 69.6k CTC Beam: 0.852 / 81.4% / 80.2% 2,966 vs 1,218 (2.44× v1, +345 over Sophro Mhiro)
german_kanzlei_ft.mlmodel (16th–17th c. German Kanzleischrift) PRODUCTION_READY CC-BY-4.0 gold12_german_kanzlei (N=12) 0.554 / 27.4% (stock CATMuS 1.6) 0.748 ± 0.155 (med 0.870, +0.194) / 18.1% (5.3–7.3% on 8/12 std charters) 53.3% / 58.5% (raw, ρ = 0.979, 23.8s/p) 1,690 vs 1,020 (+65.7%)
german_kurrent_ft.mlmodel (18th–20th c. German Kurrent) PRODUCTION_READY CC-BY-4.0 gold12_german_kurrent (N=12) 0.433 / 38.4% (stock McCATMuS) 0.601 (+0.168) / 25.7% (-12.7pp) 0.765 ± 0.074 (med 0.826, +0.332) / 66.1% / 65.9% (+ Stage 3e LightOnOCR-3-1B) 450 vs 152 (2.96×)
arabic_documentary_ft.mlmodel (v5 — Documentary & Maghrebi Arabic) PRODUCTION_READY (Maghreb codices) CC-BY-4.0 (see provenance below) gold20_arabic_regional (N=20: 10 documentary + 10 unseen Maghreb MSS) v2: 0.386 / 52.2% — 0.537 ± 0.107 / 46.7% (31.5% / 31.0%, ρ = 0.919); Maghreb slice (N=10): 0.748 / 46.0% / 50.5% (0/10 low-cert) 1,138 vs 480 (2.37× vs v2; 11th-c. Egypt 2.14×)
greek_papyrus_ft.mlmodel (v1 — 3rd-c. BCE Ptolemaic Zenon Papyri) Experimental v1 CC-BY-SA-4.0 p2_greek_papyri_byz (N=4, scriptio continua) 0.150 / 67.4% (stock PTA; Gemma-4-26B: 0.216) 0.245 (+63% rel. vs stock, beats Gemma-4-26B at 2.4× speed) / 58.2% (-9.2pp) ρ = 0.800 (13.8s/p) —
slavonic_cyrillic.mlmodel (11th–16th c. Old Church Slavonic — mirror of Cyr02full_best, Zenodo 7755483) PRODUCTION_READY (live auto-routed) CC-BY-2.0 Blind wild unseen Vatican Slavonic (MSS_Vat.slav.5 & Vat.slav.2) — conf = 0.946–0.971 (138–151 words/page in 6–27s, 36 Church Slavonic lex3 hits, preserves titlo abbreviations) Auto-routed at 100.0% Top-1 by Universal ONNX Router —
coptic_codex_ft.mlmodel (v2 — Sahidic Coptic Uncial Codices, native baselines PAGE-XML) Tier-1 PRODUCTION_READY CC-BY-SA-4.0 SCAM-A Vatican Sahidic held-out test (N=260 lines) v1 (bbox): 23.34% raw / 16.09% skel CER (97/260 exact) 13.76% raw CER / 7.35% skel CER (val_acc = 90.11%, 153/260 = 58.8% exact skel lines!) Full-page Warm Daemon: conf = 0.769, 20 Coptic lex3 hits -9.6 pp raw CER (halved skel CER vs v1!)
ethiopic_geez_ft.mlmodel (v1 — B&W Microfilm & Parchment Ethiopic/Ge'ez, HHD fine-tune) PRODUCTION_READY (B&W + parchment) CC-BY-4.0 HHD-Ethiopic test_18th (N=100 stratified 18th-c. lines) + zero-shot color Vat.et.30 pp-ocrv6-ethiopic: 65.33% Raw CER on 18th-c. B&W 31.46% Raw CER (-33.9 pp, val_acc = 80.73%, 5.3s for 100 lines); zero-shot color Vat.et.30: conf = 0.688, 5 lex3 hits Fast native .mlmodel fallback for ethiopic_geez (supports CTC Beam + 10.8k Ethiopic LM) Halved 18th-c. B&W CER (-33.9 pp)!
pp-ocrv6-ethiopic.safetensors (Medieval/Pre-Modern Ethiopic Ge'ez & Amharic — mirror of Zenodo 22757232) PRODUCTION_READY (color codices) Apache-2.0 Unseen Vatican MSS_Vat.et.30 live full-page + HHD-Ethiopic — conf = 0.904 (56 Ge'ez words in 35s via Warm Kraken 7.2 Daemon; trained on 49 medieval MSS) Auto-routed by ethiopic_geez —
pp-ocrv6-medium.safetensors (44-Language / 10-Script Historical Foundation Model — mirror of Zenodo 21788410) PRODUCTION_READY (Kraken 7.2) Apache-2.0 Inria Kraken 7.2 benchmark (chu 7.53% CER) + unseen Vat.slav.5 — Recovers polytonic Slavonic accents & titlos verbatim; supports Arab, Cyrl, Ethi, Geor, Grek, Hebr, Latn, Mlym, Syrc Native Kraken 7.2 Warm Daemon .safetensors engine —
blla_archival_ft.mlmodel (Optional archival baseline segmenter) Experimental / Do NOT set as default CC-BY-4.0 40-folio Gold-20 A/B (gold20_blla_archival_ft_ab.json) Stock blla.mlmodel: Arabic 0.4924 (1,097 hits), Hebrew 0.4721 (1,342 hits) blla_archival_ft: Arabic 0.4532 (1,018), Hebrew 0.4078 (1,086) — stock won 15W/1L/4T & 16W/1L/3T Keep stock Kraken blla.mlmodel as default (--resize union diluted baseline classes with custom Muharaf tags) —

2. Lightweight CPU ONNX Models (onnx/)

Model Size License Held-Out Benchmark Key Metrics
script_router_cnn_v1.onnx (Universal 18-route / 10-script / 9-region MobileNetV3-Small — Iter 4) 4.04 MB Apache-2.0 185 strictly unseen held-out folios across 10 scripts & 18 OCR-ready routes (incl. BOTH Sahidic SCAM-A & Bohairic Vat.copt.61 Coptic!) 90.3% Route Top-1 (167/185), 95.7% Top-2, 96.8% Script, 91.3% Region, 0.93 c. sub-century MAE, ~217 ms/page CPU (10 routes at 100.0% Top-1 incl. coptic_codex 10/10 & greek_uncial 5/5!)
text_sorter_v1.json (Stage 2 Language & Script Hygiene Sorter) 0.63 MB Apache-2.0 Multi-script + allography / code-switching test suite <1 ms/line; separates Judaeo-Arabic vs. Pure Hebrew, detects inline code-switching & Latin transliterations
masked_glyph_cnn_v1.onnx (Phase 5.3b Masked-Glyph Siamese CNN) 2.35 MB Apache-2.0 Unseen-hand masked glyph benchmark + real torn medieval glyphs (St. Gallen 751, ENA 2738.29) 99.0% full / 80.0% torn unseen-hand Top-1; doubles/triples real torn-glyph Top-3 & [abc] BracketHit for Hangman

Training Provenance & Per-Artifact Details

  • western_early_modern_ft.mlmodel (16 MB, CC-BY-4.0): Warm-started from McCATMuS V1, trained on 130 pages / 3,694 gold 16th-c. Humanist Latin lines from Bullinger Digital / Gwalther (Zenodo 4780947; val_acc = 94.69%, val_word_acc = 79.5%). Scope note: specialized for 16th-c. Humanist Latin correspondence; keep stock McCATMuS V1 as default for 17th-c. French (0.600 vs 0.335 on gold20_early_modern).
  • greek_byz_ren_ft.mlmodel (20 MB, CC-BY-SA-4.0): Warm-started from PTA greek_minuscule_s9-12_NFC (10.5281/zenodo.15838142), trained on 4,058 balanced 14th–16th c. lines (EPARCHOS + Stavronikita 14c/15c/16c; val_acc = 93.32%, val_word_acc = 74.9%).
  • syriac_codex_ft.mlmodel (16 MB, v2, CC-BY-4.0): Warm-started from Beth Mardutho / Princeton / PSL Sophro Mhiro (Zenodo 17406773, CC-BY-4.0) on balanced 2,641 Serto (ÖNB Cod. Syr. 1, 1545 CE) + 2,683 12th-c. Estrangelo (St. Mark's MS 36) lines. Bridges 6th-c. Vatican Estrangelo (Vat.sir.112: 9.9% → 76.4%, 7.7× v1) through 16th-c. Serto (27.7% CER).
  • german_kanzlei_ft.mlmodel (16 MB, CC-BY-4.0): Warm-started from CATMuS-Medieval 1.6, trained on 4,518 lines across 225 16th–17th c. Königsfelden charters (val_acc = 84.26%, val_word_acc = 51.0%).
  • german_kurrent_ft.mlmodel (16 MB, CC-BY-4.0): Warm-started from McCATMuS V1, trained on 4,503 lines across 300 19th-c. Basel Historisches Grundbuch pages (val_acc = 84.71%, val_word_acc = 51.8%).
  • arabic_documentary_ft.mlmodel (20 MB, CC-BY-4.0 / CUDL provenance): Warm-started from Muharaf (10.5281/zenodo.14295489), trained on ~13,821 balanced zero-leakage lines (PGP Egyptian documentary ×2 + unseen-MS RASAM Maghrebi + 420 Muharaf pages; val_acc = 86.11%).
  • greek_papyrus_ft.mlmodel (20 MB, CC-BY-SA-4.0): Warm-started from PTA greek_minuscule_s9-12_NFC, trained on 23 leak-free 3rd-c. BCE Ptolemaic Zenon papyri (277 PAGE-XML lines; val_acc = 49.1%).
  • slavonic_cyrillic.mlmodel (16.3 MB, CC-BY-2.0): Upstream generic Old Church Slavonic / Historic Cyrillic uncial & semi-uncial Kraken checkpoint (Cyr02full_best, Zenodo 10.5281/zenodo.7755483), mirrored here for one-command setup_reproduce.py --download-kraken-models onboarding.
  • blla_archival_ft.mlmodel (4.9 MB, CC-BY-4.0): Experimental optional baseline segmenter trained on 100%-complete gold PAGE-XMLs from RASAM + Muharaf (val_bl_f1 = 0.939, val_freq_iu = 0.881).
  • lexicons/_ocr_{lexicon,bigrams}_*.json (CC-BY-4.0 / Apache-2.0): Strictly zero-leakage historical dictionaries & word-bigram LMs for Hebrew, Arabic, Syriac (69.7k, ρ = 0.976), Greek (70.9k), Latin (56.7k, ρ = 0.931), German (8.8k, ρ = 0.979), European (27.8k, ρ = 0.963), and Sanskrit.

Citation & Source Code

Downloads last month
130
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support