Usage
vLLM (recommended)
Tested with vllm/vllm-openai:v0.32.0:
vllm serve altslate/indic-ocr-0.9b --served-model-name ocr --trust-remote-code --max-model-len 8192 \ --limit-mm-per-prompt '{"image": 1}'
import base64, requestsimg = base64.b64encode(open("block.png", "rb").read()).decode()r = requests.post("http://localhost:8000/v1/chat/completions", json={ "model": "ocr", "temperature": 0, "max_tokens": 2048, "messages": [{"role": "user", "content": [ {"type": "image_url", "image_url": {"url": f"data:image/png;base64,{img}"}}, {"type": "text", "text": "OCR:"}]}]})print(r.json()["choices"][0]["message"]["content"])
Tested with transformers 5.23.0 and torch 2.14:
import torchfrom PIL import Imagefrom transformers import AutoProcessor, AutoModelForImageTextToText model = AutoModelForImageTextToText.from_pretrained("altslate/indic-ocr-0.9b", dtype=torch.bfloat16).to("cuda").eval()processor = AutoProcessor.from_pretrained("altslate/indic-ocr-0.9b")image = Image.open("block.png").convert("RGB")messages = [{"role": "user", "content": [{"type": "image", "image": image}, {"type": "text", "text": "OCR:"}]}]inputs = processor.apply_chat_template(messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt").to(model.device)out = model.generate(**inputs, max_new_tokens=1024, do_sample=False, repetition_penalty=1.05)print(processor.decode(out[0][inputs["input_ids"].shape[-1]:], skip_special_tokens=True))
The prompt is always OCR:. The model was trained only on that task; the other PaddleOCR-VL prompts (tables, formulas, charts)
were not trained further and may have degraded.
Results
Sarvam Indic OCR Bench, scored with the benchmark's own metrics.py --normalize. Word accuracy = 100 × (1 − WER), averaged
over blocks. All models were run by us, in the same harness, greedy decoding:
- this model: vLLM v0.32.0, prompt
OCR:;
- Patram 1.5 7B: vLLM v0.30.0 with BharatGen's own vLLM patch and chat template, a plain "transcribe exactly" prompt;
- Surya OCR 2.5: vLLM v0.30.0, Surya's own block prompt, image resizing and sampling settings from the
surya-ocr package
(0.24.0), its HTML output converted to plain text. (On vLLM v0.32.0 Surya returned empty output for 59% of blocks, so we used
v0.30.0; its valid-block word accuracy there, 70.0, matches the number Sarvam publishes for it.)
The benchmark's word_accuracy leaves out blocks with an empty prediction. This model and Patram had none on either split; Surya had 6
(representative split) and 46 (full test), so its numbers are very slightly flattered.
Overall
Table with columns: Split, Model, Params, Licence, Word acc, Valid-block word acc, Valid-block CER, Loops| Split | Model | Params | Licence | Word acc | Valid-block word acc | Valid-block CER | Loops |
|---|
| representative (1,173 blocks) | indic-ocr-0.9b | 0.9B | Apache-2.0 | 62.3 | 65.2 | 0.165 | 55 |
| representative | Patram 1.5 | 7B | Apache-2.0 | 46.0 | 50.2 | 0.279 | 102 |
| representative | Surya OCR 2.5 | 0.7B | OpenRAIL-M (modified) | 63.9 | 66.9 | | 55 |
| full test (6,908 blocks) | indic-ocr-0.9b | 0.9B | Apache-2.0 | 63.8 | 67.2 | 0.148 | 386 |
| full test | Patram 1.5 | 7B | Apache-2.0 | 47.0 | 50.7 | 0.271 | 534 |
| full test | Surya OCR 2.5 | 0.7B | OpenRAIL-M (modified) | 67.1 | 70.0 | | 291 |
"Loops" = blocks the benchmark flags as repetition loops or catastrophic output; "valid-block" columns leave those out.
Per language, representative split (word accuracy)
Table with columns: Language, indic-ocr-0.9b, Patram 1.5 7B, Surya OCR 2.5| Language | indic-ocr-0.9b | Patram 1.5 7B | Surya OCR 2.5 |
|---|
| Assamese | 66.6 | 40.4 | 76.5 |
| Bengali | 70.7 | 56.8 | 76.2 |
| Bodo | 63.2 | 44.4 | 52.5 |
| Dogri | 56.2 | 44.5 | 57.0 |
| English | 94.8 | 97.5 | 95.3 |
| Gujarati | 65.4 | 50.3 | 60.5 |
| Hindi | 80.1 | 77.9 | 85.2 |
| Kannada | 65.5 | 36.5 | 74.7 |
| Kashmiri | 22.1 | 7.8 | 28.3 |
| Konkani | 82.2 | 71.6 | 77.6 |
| Maithili | 79.9 | 59.1 | 77.7 |
| Malayalam | 50.7 | 48.3 | 73.4 |
| Manipuri (Meetei Mayek) | 55.8 | 0.0 | 0.0 |
| Marathi | 80.9 | 75.4 | 85.1 |
| Nepali | 76.6 | 77.3 | 77.4 |
| Odia | 34.3 | 18.1 | 60.9 |
| Punjabi | 75.6 | 51.7 | 84.7 |
| Sanskrit | 46.2 | 37.6 | 46.9 |
| Santhali (Ol Chiki) | 37.3 | 17.2 | 5.1 |
| Sindhi | 71.9 | 64.0 | 77.9 |
| Tamil | 77.3 | 53.0 | 79.0 |
| Telugu | 76.4 | 41.1 | 69.3 |
| Urdu | 52.2 | 28.8 | 77.3 |
Per language, full test (word accuracy)
Table with columns: Language, indic-ocr-0.9b, Patram 1.5 7B, Surya OCR 2.5| Language | indic-ocr-0.9b | Patram 1.5 7B | Surya OCR 2.5 |
|---|
| Assamese | 79.2 | 45.1 | 83.7 |
| Bengali | 75.3 | 54.4 | 78.4 |
| Bodo | 70.7 | 48.2 | 57.7 |
| Dogri | 62.7 | 47.8 | 64.8 |
| English | 95.8 | 97.3 | 94.6 |
| Gujarati | 59.1 | 43.9 | 60.8 |
| Hindi | 77.9 | 77.5 | 83.0 |
| Kannada | 63.1 | 39.4 | 73.4 |
| Kashmiri | 21.6 | 6.8 | 26.3 |
| Konkani | 88.7 | 75.6 | 78.5 |
| Maithili | 81.0 | 62.4 | 71.1 |
| Malayalam | 50.5 | 48.6 | 73.7 |
| Manipuri (Meetei Mayek) | 56.0 | 0.0 | 0.0 |
| Marathi | 79.0 | 76.4 | 83.9 |
| Nepali | 81.9 | 83.0 | 78.2 |
| Odia | 37.8 | 16.9 | 65.3 |
| Punjabi | 69.1 | 47.9 | 79.2 |
| Sanskrit | 46.2 | 32.7 | 57.0 |
| Santhali (Ol Chiki) | 36.4 | 14.3 | 9.8 |
| Sindhi | 77.4 | 65.4 | 83.3 |
| Tamil | 78.7 | 57.7 | 77.1 |
| Telugu | 74.3 | 39.9 | 66.0 |
| Urdu | 55.5 | 27.9 | 82.2 |
Limitations
- Weak on Odia and Malayalam (38 and 51 word accuracy on the full test), and well behind Surya on Urdu (56 vs 82), Kannada
and Punjabi. Real print was added only for Malayalam, Kannada, Odia, Telugu, Gujarati and Punjabi; Urdu and the rest are still
trained on synthetic renders only.
- Script confusion: on a few Telugu pages it still writes Kannada script (22 of 300 full-test Telugu blocks are mostly Kannada
script, down from 114 in the first release), and on some Santhali pages it confuses Ol Chiki with Meetei Mayek. Check the output
script if this matters.
- Small regressions vs the first release (full test): English 97.2 → 95.8, Manipuri 60.0 → 56.0, Sindhi 79.5 → 77.4,
Dogri 64.1 → 62.7. The first release is kept under the
v4 tag (revision="v4").
- Repetition loops on about 6% of full-test blocks (386 of 6,908), mostly long or very dense blocks. Use
repetition_penalty around 1.05 and a max_tokens limit; split very long blocks.
- Printed text only. Not trained on handwriting, tables, formulas or scene text.
- Blocks, not pages. Full pages exceed what it was trained on; crop first.
- Kashmiri (20 word accuracy) is not usable yet.
Training
Six rounds of full fine-tuning from PaddleOCR-VL-1.6 (8k + 6k + 3k + 2k steps on synthetic data, then 4k + 3k steps on real print
plus synthetic replay; batch 8, lr 1e-5, cosine schedule, loss on the answer only). Checkpoints were chosen only on our own dev sets:
a synthetic dev set (held-out fonts and sentences) and real-print strips from Wikisource books held out of training (1,411 strips,
whole books). The Sarvam benchmark was used for evaluation only, never for training or checkpoint selection.
Real print (rounds 5–6): about 42k text blocks cut from page scans of public-domain and CC-licensed books on Malayalam, Kannada,
Odia, Telugu, Gujarati and Punjabi Wikisource, paired with the human-proofread text of the same page (Wikisource text: CC BY-SA 4.0;
scans: public domain or CC, recorded per page; pages without a free scan licence were skipped). Text lines were found from the ink
profile; our own earlier model's OCR was used only to locate each block's span in the proofread page, and the label is the proofread
text, never the OCR. Blocks whose OCR disagreed too much with the matched span, or that contained lines absent from the page text
(headers, page numbers, footnotes), were dropped. Test-leak guard: any block sharing a 6-word sequence with the benchmark's ground
truth for its language was removed.
Synthetic data (rounds 1–4, and replayed in 5–6), rendered with Pillow + raqm (HarfBuzz shaping) with scan-like degradations (noise, blur, rotation,
low-resolution rescans, an "old print" profile with faded ink, bleed-through and speckle):
- text: Dakshina native-script Wikipedia sentences (train split; CC BY-SA 4.0), the Indic side of allenai/nllb (ODC-BY 1.0),
Wikipedia 20231101 dumps for Assamese, Odia, Nepali, Maithili, Sanskrit, Konkani, Santhali, Manipuri and Kashmiri
(CC BY-SA 4.0), English sentences from allenai/nllb;
- fonts: open fonts from Google Fonts (OFL) and Indic print fonts from the Ubuntu archive (Lohit, SMC, Samyak, Gubbi, Kalapi,
Uniol and others; OFL or GPL with the font exception). Fonts were used to render training images and are not redistributed;
- mixed-script blocks: English words and lines inside Indic text, each word drawn in a font of its own script, and bilingual blocks
that alternate lines of two languages (Santhali and Manipuri with Bengali, the others with English);
- test-leak guard: every sentence that appears in the benchmark's ground truth for its language was removed before rendering.
No closed or proprietary models were used to make the data.
Versions
Table with columns: Revision, Full-test word acc, Notes| Revision | Full-test word acc | Notes |
|---|
main (Nov 30, 2026) | 63.8 | + real print for ml/kn/or/te/gu/pa |
v4 (Nov 28, 2026) | 59.2 | first release, synthetic data only |
Licence
Apache-2.0, the same as the base model. The training text came from CC BY-SA 4.0 and ODC-BY 1.0 sources, and the real-print
images from public-domain and CC-licensed scans; no text or images are distributed with the model.
Citation
If you use it, please cite this repository and the base model, PaddleOCR-VL (PaddlePaddle). Benchmark: Sarvam AI, Indic OCR Bench.