Kraken vs Donut
Pick Kraken for historical manuscripts, early prints and right-to-left or other non-Latin scripts, where you can train on your own material and need ALTO or PageXML output. Pick Donut for field extraction from narrow, fixed-layout documents such as receipts and forms after fine-tuning. Neither works well out of the box, so the main split is document type: old and non-Latin text lines versus structured fields.
Krakenkraken/kraken | Donutnaver/donut | |
|---|---|---|
| Type | Open source | Open source |
| Price | 1 credit / page | 1 credit / page |
| Per 1,000 pages | $1.00 | $1.00 |
| Typical speed | 1.5 s / page | 1.0 s / page |
| Best for | Historical documents and manuscripts | Receipt and form fields after fine-tuning |
| Inputs | images | images |
| Languages | Many scripts, incl. right-to-left | English, Chinese, Japanese, Korean |
| Max pages per request | 500 | 100 |
| Tables | No | No |
| Handwriting | ✓ Yes | No |
| Math | No | No |
| Bounding boxes | ✓ Yes | No |
| Confidence | No | No |
| Forms | No | ✓ Yes |
| Multilingual | ✓ Yes | No |
| On OCRRouter | Available | Available |
Prices are what you pay on OCRRouter. Speed is the provider's typical figure, not a benchmark we ran.
Which to choose
Choose Kraken if
- You are transcribing historical manuscripts or early prints, or working in Arabic, Hebrew or other RTL scripts.
- You need ALTO, PageXML, hOCR or bounding boxes that digital humanities tools can read.
- You want to train layout analysis, reading order and character recognition yourself, or start from community models on Zenodo.
Choose Donut if
- You need structured JSON for receipts or form fields without a separate OCR step.
- Your documents are narrow, fixed-layout types, and you can fine-tune. One HN practitioner reports about 200 documents can reach human-level accuracy on narrow data.
- You want an MIT-licensed model that loads through Hugging Face Transformers.
Key differences
| Kraken | Donut | |
|---|---|---|
| What it is | OCR system for historical and non-Latin material, with trainable layout analysis and recognition | OCR-free document understanding transformer (Swin encoder plus BART decoder), ECCV 2022 |
| Licence | Apache-2.0 | MIT |
| How you run it | Python library via pip on Linux or macOS, x64 or ARM, Python 3.10 to 3.13. No Windows support | Self-hosted base model, loaded from Hugging Face Transformers. Transformers v5 dropped image-to-text pipeline support, so load it directly or use v4 |
| Price | Free, self-hosted (you pay for compute) | Free, self-hosted (you pay for compute) |
| Output formats | ALTO, PageXML, hOCR, plain text, bounding boxes | JSON, plain text |
| Training needed | Usually needs training on your own material for good accuracy | Base checkpoint is pretrain-only and must be fine-tuned before use |
| Known failure | Install can fail with a dependency conflict (issue #816). Learned line order is lost in segmentation and text output (issue #820) | Misses tiny text in large images because of input resolution limits. One HN user found results on personal documents did not match the promised scores |
Sources
- Kraken GitHub README
- Kraken docs
- Zenodo OCR models
- donut-base model card
- Donut ECCV paper
- Hacker News thread
What each one is
Kraken
OCR engine for historical documents and manuscripts, with trainable models for unusual scripts.
Kraken detailsDonut
OCR-free document understanding model. Fine-tuned for receipts, forms and document Q&A.
Donut detailsTry both on your own file
Run the file once with each model and compare the output.
Use one, fall back to the other
{"model": "kraken/kraken","fallbacks": ["naver/donut"],"file_url": "https://example.com/document.pdf"}Questions
More comparisons
Kraken alternativesDonut alternativesBest OCR models in 2026