Qianfan OCR vs Kraken
Pick Qianfan OCR for parsing modern documents with tables, formulas and handwriting in 192 languages, on a GPU you control. Pick Kraken for historical manuscripts, early prints and right-to-left scripts, where you can train layout and recognition on your own material. The main split is the material: Qianfan OCR is a ready-made 4B parsing model, while Kraken is a trainable toolkit.
Qianfan OCRbaidu/qianfan-ocr | Krakenkraken/kraken | |
|---|---|---|
| Type | OCR API | Open source |
| Price | 2 credits / page | 1 credit / page |
| Per 1,000 pages | $2.00 | $1.00 |
| Typical speed | 2.0 s / page | 1.5 s / page |
| Best for | Chinese documents | Historical documents and manuscripts |
| Inputs | PDF, images | images |
| Languages | Chinese, English and more | Many scripts, incl. right-to-left |
| Max pages per request | 200 | 500 |
| Tables | ✓ Yes | No |
| Handwriting | ✓ Yes | ✓ Yes |
| Math | ✓ Yes | No |
| Bounding boxes | No | ✓ Yes |
| Confidence | No | No |
| Forms | No | No |
| Multilingual | ✓ Yes | ✓ Yes |
| 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 Qianfan OCR if
- You parse modern documents and want Markdown, JSON, HTML, LaTeX or bounding boxes in one model.
- You need tables, formulas, key information extraction or handwriting across 192 languages without training anything.
- You want a published benchmark: 93.12 on OmniDocBench v1.5, 79.8 on olmOCR-Bench and 880 on OCRBench.
Choose Kraken if
- You transcribe historical manuscripts or early prints and want to train layout analysis, reading order and recognition on your own material.
- You work with Arabic, Hebrew or other right-to-left, BiDi or top-to-bottom scripts.
- You feed digital humanities tools that expect ALTO, PageXML, abbyyXML or hOCR, and you want community-trained models from the public Zenodo repository.
Key differences
| Qianfan OCR | Kraken | |
|---|---|---|
| Built for | End-to-end document parsing, key information extraction, tables and formulas | Historical documents and non-Latin scripts, with trainable layout and recognition |
| Licence | Apache-2.0, commercial use allowed | Apache-2.0 |
| How you run it | Open weights on Hugging Face, or hosted on the Baidu Qianfan platform. Benchmarked on one NVIDIA A100 with vLLM. | Python library installed with pip on Linux or macOS, x64 or ARM, Python 3.10 to 3.13. No Windows support. |
| Output formats | Markdown, JSON, HTML, LaTeX, bounding boxes | ALTO, PageXML, hOCR, plain text, bounding boxes |
| Benchmarks | OmniDocBench v1.5 93.12, olmOCR-Bench 79.8, OCRBench 880 (reported by the authors) | Not published |
| Languages and scripts | 192 languages, handwriting and scene text | Right-to-left, BiDi and top-to-bottom scripts, with community models on Zenodo |
| Known failure | Speed of 1.024 pages per second on an A100 even with W8A8. Thinking mode can emit up to 16,384 tokens, adding latency. Not for CPU-only deployment. | Install can fail with a dependency conflict (issue #816). Learned line order is lost in segmentation and text output (issue #820). Usually needs training for good accuracy. |
Sources
What each one is
Qianfan OCR
Baidu's OCR-tuned vision model. Strong on Chinese documents and tables.
Qianfan OCR detailsKraken
OCR engine for historical documents and manuscripts, with trainable models for unusual scripts.
Kraken 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": "baidu/qianfan-ocr","fallbacks": ["kraken/kraken"],"file_url": "https://example.com/document.pdf"}Questions
More comparisons
Qianfan OCR alternativesKraken alternativesBest OCR models in 2026