WorksComputer Science
DictaRashi: A State-of-the-Art OCR Model For Rashi Script
Abstract
We release DictaRashi, a Tesseract OCR model for scanned Hebrew books printed in the so-called "Rashi" font. We trained DictaRashi on over one million manually corrected lines of text from over 100 different books of Rabbinic and post-Rabbinic literature. On a held-out set of 1,120 manually transcribed lines from scanned Rashi-script pages, DictaRashi reaches a character error rate (CER) of 0.86% and a word error rate (WER) of 3.38%, setting a new state-of-the-art for publicly-available Tesseract models. We provide a full comparison of our results to those of the 31 other publicly available Hebrew Tesseract models; the best of those models achieves a 2.98% CER and 11.86% WER. We further demonstrate that DictaRashi outperforms the current frontier LLMs on this OCR task. We release the test set of Rashi-script documents so that it may be used as a benchmark for future work in this area. We are pleased to release the model and test set to the community under a CC BY NC 4.0 license.
Introduction
A large percentage of published Rabbinic and post-Rabbinic books are set in the so-called "Rashi" script, a semi-cursive Hebrew typeface. Millions of such pages are available as bitmap scans, but full-text search, digital editions and downstream NLP all depend on OCR, and Rashi script is poorly served by general-purpose engines: the official Tesseract Hebrew models read most Rashi letters as their square-script look-alikes and their character-level error rate is generally no lower than 30% (§ 4).
Several community models fine-tuned for Rashi script exist (§ 3.2), but they have not previously been compared on a common, manually verified test set. On this backdrop, this technical report makes three key contributions:
We release
DictaRashi, a new Tesseract model trained on over one million manually corrected lines from over 100 Rabbinic and post-Rabbinic books, runnable with a stock Tesseract installation.We create and release a new benchmark for Rashi-script OCR evaluation, consisting of 1,120 lines scanned text from a wide assortment of Rabbinic and post-Rabbinic books, along with ground truth prepared by domain experts.
We present a comprehensive comparison and evaluation of 32 open Hebrew Tesseract models as well as 8 leading LLMs on the aforementioned test set of 1,120 hand-transcribed Rashi-script lines.
Model and Training
Starting point
We performed our train as a continuous train on top of the standard heb model from tessdata_best (version string 4.00.00alpha:heb:synth20170629), keeping its weights unchanged:
[1,36,0,1 Ct3,3,16 Mp3,3 Lfys48 Lfx96 Lrx96 Lfx192 Olc1]
Training data
Table 1 summarizes the data. Pages reserved as test pages for each book are excluded.
Procedure
Our training used the tesstrain scripts1 with Tesseract 5.2.0-51-ga8735. Each training sample is one text line image paired with its transcription, rendered as a single line (page segmentation mode 7). Tesstrain was run in fine-tuning mode (START_MODEL=heb) with LANG_TYPE=RTL, which implies Unicode normalization mode 3 and builds the language model with -pass_through_recoder -lang_is_rtl. The pipeline:
| Books | 118 |
| Pages | 14,195 |
| Text lines | 1,343,425 |
| Words | 12,724,738 |
| Characters (non-space) | 52,517,573 |
| Distinct word forms | 389,194 |
| Pages per book (median) | 96 |
| Words per page (median) | 821 |
Table 1. Training data.
concatenates all transcriptions and builds the character set;
converts every line transcription into a box file and every image/box pair into an
.lstmfsample;shuffles the samples and splits them into training and evaluation lists;
runs
lstmtrainingfrom thehebcheckpoint.
Training ran for 500,000 iterations with the default tesstrain learning rate. The released model is the final checkpoint in floating-point form.
Test Corpus
Test pages
The test set consists of 14 Rashi-script pages from typical out-of-copyright Rabbinic and post-Rabbinic books, scanned anew from physical volumes for this evaluation using a Fujitsu ScanSnap SV600 overhead scanner. We have ensured that there is no duplication between the test pages and the training set. Altogether, the pages of the test set contain 1,120 lines, 11,294 words, and 51,749 characters.3
Ground truth
Domain experts prepared transcriptions for each of these lines using a web annotation tool.
Line Images and Bounding Boxes
The pages are divided into 1,120 lines via Tesseract’s layout segmentation routine, using the "auto" setting (PSM=3), which provides bounding boxes for each of the lines. These bounding boxes are considered canonical for the purposes of the test set; when evaluating each OCR system, we request transcription of the lines one at a time, always with these same bounding boxes.
Test Corpus Release Package
The test set release includes the page images, the bounding boxes and the ground-truth transcriptions.
Evaluation Setup
Metrics
We measure CER (character error rate) and WER (word error rate) for each evaluated model across the test corpus. Before scoring, both sides are Unicode NFC-normalized; vowel points, cantillation marks and invisible bidirectional or zero-width characters are removed; every character other than Hebrew letters, digits and spaces is dropped; and whitespace runs are collapsed.
Baselines
We compare our model to 31 publicly-available models Hebrew Tesseract models, including the following:
the official
tessdata,tessdata_bestandtessdata_fastmodels, bothheband thescript/Hebrewmodel;4three historical official releases;5
HeOCR R6, R7 and R8b;6
Rivok, all published releases;7
Pninim Rashi;8
Boro11204;9
EastEriq Rashi.10
LLMs
We also compare our model’s performance to that of the leading frontier commercial LLMs. We compare to eight such LLMs, with reasoning effort set to medium, and with the following prompt: <transcribe exactly as printed, without adding vowel points>.11 Each model received each line image in a separate request, just as the Tesseract models did.12 Empty responses count as empty output.
Results
Tesseract models. Table 2 provides comparative results for all models. DictaRashi reaches 0.86% CER and 3.38% WER, against 2.98% / 11.86% for the next best model (Boro11204 heb_rashi7): about three and a half times fewer errors in both characters and words. The official Tesseract models, HeOCR and the historical models stay above 30% CER: they were trained on square script and read Rashi letters as their square-script look-alikes.
| Provider | Model | CER | WER |
| Dicta | DictaRashi (this release) | 0.86 | 3.38 |
| Boro11204 | heb_rashi7 | 2.98 | 11.86 |
| Boro11204 | heb_rashi6 | 3.12 | 12.33 |
| Boro11204 | heb_rashi5 | 3.52 | 14.32 |
| Boro11204 | heb_rashi4 | 5.84 | 23.19 |
| Boro11204 | heb4 | 22.82 | 66.04 |
| Rivok | v2.0 heb_rivok | 5.84 | 20.84 |
| Rivok | v2.0 heb_rivok (best) | 5.87 | 20.96 |
| Rivok | v2.0 heb_rivok_lite (best) | 6.95 | 24.36 |
| Rivok | v2.0 heb_rivok_lite | 7.08 | 24.59 |
| Rivok | v1.0.1 heb_rivok (best) | 20.96 | 60.44 |
| Rivok | v1.0 heb_rivok (best) | 20.96 | 60.44 |
| Rivok | v1.0.1 heb_rivok | 21.10 | 60.55 |
| Rivok | v1.0 heb_rivok | 21.10 | 60.55 |
| Rivok | v1.0.1 heb_rivok_lite (best) | 27.05 | 71.80 |
| Rivok | v1.0.1 heb_rivok_lite | 27.27 | 72.15 |
| Pninim Rashi | heb_rashi | 13.57 | 42.84 |
| Pninim Rashi | heb_rashi_fast | 13.65 | 43.02 |
| EastEriq Rashi | heb-ras | 29.02 | 80.64 |
| EastEriq Rashi | heb-rashi-stam4 | 58.12 | 129.21 |
| Official Tesseract | tessdata_best heb | 33.73 | 82.81 |
| Official Tesseract | tessdata heb | 34.28 | 83.81 |
| Official Tesseract | tessdata_fast heb | 34.93 | 83.95 |
| Official Tesseract | tessdata script/Hebrew | 37.38 | 86.09 |
| Official Tesseract | tessdata_best script/Hebrew | 37.52 | 86.09 |
| Official Tesseract | tessdata_fast script/Hebrew | 37.70 | 86.03 |
| HeOCR | r6 | 35.44 | 81.86 |
| HeOCR | r7 | 35.73 | 82.50 |
| HeOCR | r8b | 36.67 | 82.85 |
| Tesseract historical | 4.00 heb | 38.99 | 86.90 |
| Tesseract historical | 3.04.00 heb | 45.23 | 88.49 |
| Tesseract historical | initial (2014) heb | 52.03 | 98.05 |
Table 2. CER and WER (%, lower is better) of all 32 open Tesseract Hebrew models on the 1,120 lines of our test set. Providers are ordered by their best CER; “(best)” marks Rivok’s full-precision tessdata_best-based variants. Note that in one case WER goes above 100%, because extra words count as errors, and thus, a model which outputs more words than exist in the ground truth may end up with a WER of over 100%.
LLMs. Table 3 shows a wide spread across LLMs. The best performing LLM is Claude Fable 5.2 which reaches 2.90% CER and 8.46% WER, still substantially below the performance of DictaRashi. Gemini 4 Argon (3.85% / 9.48%) and Claude Opus 5.5 (4.42% / 11.81%) follow; the remaining five models range from 7.50% to 18.30% CER.
| Provider | Model | CER | WER |
| Anthropic | Claude Fable 5.2 | 2.90 | 8.46 |
| Gemini 4 Argon | 3.85 | 9.48 | |
| Anthropic | Claude Opus 5.5 | 4.42 | 11.81 |
| Alibaba | Qwen4 Max | 7.50 | 21.96 |
| Gemini 4 Hydrogen | 10.20 | 24.92 | |
| OpenAI | GPT-6.2 Astra | 13.70 | 32.42 |
| xAI | Grok 4.7 | 14.60 | 37.30 |
| Anthropic | Claude Sonnet 5.5 | 18.30 | 38.74 |
| Dicta | DictaRashi | 0.86 | 3.38 |
Table 3. CER and WER (%, lower is better) of eight frontier LLMs on the same 1,120 line images, with DictaRashi for reference.
Error analysis The most frequent errors in the DictaRashi results are between visually close Rashi letters (Table 4): vav read as yod, het and tav in both directions, and het read as pe. The ten pairs in the table account for nearly one third of the errors.
| A | B | A→B | B→A | Total |
| vav | yod | 30 | 4 | 34 |
| het | tav | 15 | 12 | 27 |
| het | pe | 15 | 0 | 15 |
| kaf | nun | 1 | 13 | 14 |
| gimel | nun | 0 | 13 | 13 |
| bet | nun | 7 | 6 | 13 |
| final mem | samekh | 3 | 9 | 12 |
| bet | gimel | 9 | 0 | 9 |
| he | final mem | 0 | 7 | 7 |
| alef | tav | 1 | 5 | 6 |
Table 4. The ten most frequent letter confusions of DictaRashi on the 1,120 test lines. A→B: ground-truth letter A read as B.
Usage
The model is a standard .traineddata file and needs no code beyond Tesseract 5:
tesseract page.png out \
--tessdata-dir ./models \
-l DictaRashi --psm 3
The model, the test set and usage examples are available on Github.13
Interactive Website
We provide an interactive website where users can upload scanned Rashi-script documents and receive OCR results from our DictaRashi model.14
Future Work
We are currently pursing additional avenues to achieve even higher accuracy on Rashi-script books using transformer-based models such as TrOCR.
Conclusion
DictaRashi sets a new state-of-the-art for Rashi-script OCR, and outperforms frontier LLMs as well. We are pleased to release it to the NLP community.
References
No references were extracted for this paper.