Most OCR models are built for Latin and CJK scripts. They work great for English, Chinese, Japanese, and European languages. But throw Arabic, Devanagari, Thai, or Cyrillic at them, and quality drops fast. dots.ocr was built to solve this problem.
At 1.7B parameters, dots.ocr is a mid-size model focused on one thing: reading any script, any language, any writing system. If you process documents in diverse scripts, especially in regions like India, Southeast Asia, or the Middle East, dots.ocr is the best open-source option available.
What is dots.ocr?
dots.ocr comes from dots.llm, a project focused on multilingual document understanding. The model is trained on a massive corpus of documents in hundreds of scripts, with special attention to writing systems that other models ignore.
The key insight: most OCR models are trained primarily on Latin and CJK data, then โalso supportโ other scripts as an afterthought. dots.ocr inverts this priority. Itโs trained script-agnostic from the start, which means it handles mixed-script documents and rare writing systems better than models that treat them as edge cases.
Key Specs
| Spec | Value |
|---|---|
| Parameters | 1.7B |
| License | Apache 2.0 |
| Languages | Any script (hundreds) |
| Multi-page | No (page-by-page) |
| Table detection | Yes (cell-level bounding boxes) |
| Layout recognition | Yes |
| Equation support | LaTeX |
| Min hardware | 6 GB VRAM |
What makes it different
Script-agnostic architecture: Unlike models trained on specific language families, dots.ocr handles any writing system. Latin, CJK, Cyrillic, Arabic, Devanagari, Thai, Hebrew, Greek, Armenian, Georgian, Khmer, Lao, Myanmar, Tibetan, and more. If the script exists, dots.ocr probably handles it.
Mixed-script documents: Many real-world documents mix scripts. A contract might have English headings, Arabic names, and local language clauses. Most OCR models struggle with this. dots.ocr handles mixed-script documents naturally because it doesnโt assume a single script per document.
Cell-level table bounding boxes: Table extraction includes bounding boxes for individual cells, not just rows and columns. This is useful for structured data extraction where you need to know exactly which cell contains which value.
LaTeX equation support: Academic and technical documents with equations are handled. Not as strong as GOT-OCR 2.0 on complex math, but better than most general-purpose OCR models.
Benchmarks
Direct benchmark comparisons are limited because dots.ocr hasnโt been included in most standard OCR benchmarks yet. Hereโs what we know:
| Model | Params | Multilingual Score | Table Accuracy | Speed |
|---|---|---|---|---|
| dots.ocr | 1.7B | Best (script-agnostic) | Good (cell-level) | Moderate |
| Surya | 650M | Very Good (90+ langs) | Good | Fast |
| Baidu Unlimited-OCR | 3B | Good (40+ langs) | Excellent (HTML) | Moderate |
| Florence-2 | 770M | Good (100+ langs) | Poor | Fast |
For Latin and CJK scripts, dots.ocr is comparable to Surya and Baidu Unlimited-OCR. For non-Latin, non-CJK scripts (Arabic, Devanagari, Thai, etc.), dots.ocr significantly outperforms all competitors.
Setup
Installation
pip install dots.ocr
Or from source:
git clone https://github.com/nickmuchi/dots.ocr.git
cd dots.ocr
pip install -e .
Basic usage
from dots_ocr import DotsOCR
# Initialize the model
ocr = DotsOCR()
# Process an image
result = ocr.process("document.png")
# Access text results
for block in result.blocks:
print(f"Text: {block.text}")
print(f"Bounding box: {block.bbox}")
print(f"Confidence: {block.confidence}")
print(f"Script: {block.script}")
Processing with specific scripts
from dots_ocr import DotsOCR
ocr = DotsOCR()
# Process Arabic document
result = ocr.process("arabic_doc.png", scripts=["arabic"])
# Process mixed-script document
result = ocr.process("mixed_doc.png") # auto-detects scripts
# Process with table extraction
result = ocr.process("table_doc.png", extract_tables=True)
for table in result.tables:
print(f"Table at {table.bbox}")
for row in table.rows:
for cell in row.cells:
print(f" Cell: {cell.text} at {cell.bbox}")
Batch processing
import os
from dots_ocr import DotsOCR
ocr = DotsOCR()
# Process all images in a directory
image_dir = "./documents"
for filename in os.listdir(image_dir):
if filename.endswith(('.png', '.jpg', '.jpeg')):
filepath = os.path.join(image_dir, filename)
result = ocr.process(filepath)
print(f"--- {filename} ---")
for block in result.blocks:
print(block.text)
When to use dots.ocr
- You process documents in diverse scripts (Arabic, Devanagari, Thai, etc.)
- You handle mixed-script documents (multiple writing systems per page)
- You need cell-level table bounding boxes
- You process documents from India, Southeast Asia, Middle East, or Central Asia
- You need LaTeX equation support alongside multilingual text
When to use something else
- Latin/CJK only, maximum speed: Surya (650M, faster)
- Multi-page PDFs: Baidu Unlimited-OCR (single-pass multi-page)
- Academic papers with heavy math: GOT-OCR 2.0 (better equation handling)
- Ultra-lightweight: PaddleOCR-VL (34.5M params)
- No GPU: Tesseract 5 (CPU-only)
My take
dots.ocr fills a gap that other OCR models ignore. If you process documents in Latin and CJK only, Surya or Baidu Unlimited-OCR are better choices. But the moment you need Arabic, Devanagari, Thai, or any non-Latin, non-CJK script, dots.ocr is the only serious open-source option.
The 1.7B parameter size is reasonable. Itโs not tiny, but it runs on a 6 GB GPU without issues. Speed is moderate, not as fast as Surya but not painfully slow either.
If you work with documents from India, Southeast Asia, the Middle East, or Central Asia, dots.ocr should be your first choice. For everything else, Surya or Baidu Unlimited-OCR are probably better.
FAQ
Is dots.ocr better than Surya?
For Latin and CJK scripts, theyโre comparable. Surya is faster (650M vs 1.7B). For non-Latin, non-CJK scripts (Arabic, Devanagari, Thai), dots.ocr is significantly better.
What scripts does dots.ocr support?
Any script. Latin, CJK, Cyrillic, Arabic, Devanagari, Thai, Hebrew, Greek, Armenian, Georgian, Khmer, Lao, Myanmar, Tibetan, and more. Itโs trained script-agnostic, so it handles writing systems that other models donโt even attempt.
Can I use dots.ocr commercially?
Yes. dots.ocr uses the Apache 2.0 license, which allows commercial use, modification, and redistribution without restrictions.
How fast is dots.ocr?
Moderate. Not as fast as Surya (650M) but faster than Baidu Unlimited-OCR (3B). On an RTX 3060, expect 15-30 pages per minute depending on document complexity.
Does dots.ocr handle tables?
Yes, with cell-level bounding boxes. Table extraction is good but not as polished as Baidu Unlimited-OCRโs HTML table output. For structured table data, dots.ocr provides the raw cell data that you can format as needed.
How do I run dots.ocr on a server?
Use the Python API with a web framework like FastAPI. Process images in batches for efficiency. See the setup section above for code examples.