Skip to content
Computer vision

Surya OCR 2.5

компактная OCR для сложных документов

2 min read

Surya 2.5 от Datalab — OCR-модель на 689M параметров. Через единый VLM она выполняет распознавание текста, layout-анализ и разбор таблиц на изображениях и PDF, выдавая блоки в порядке чтения и HTML-представление содержимого.

Ключевые особенности

  • Точность: 85.9 на OmniParseBench — лучший результат среди открытых моделей до 1B, которые оценивали авторы; 83.7% на olmOCR-bench.
  • Скорость: 4.5 страниц/с на одной H100 при 192 DPI; в 1.7 раза быстрее Surya 2 с MTP.
  • Мультиязычность: 74.9% на внутреннем бенчмарке из 91 языка.
  • Layout analysis: таблицы, изображения, заголовки и другие блоки с reading order; таблицы — в HTML, объединённые ячейки через colspan/rowspan.
  • Дополнительно: отдельные меньшие модели для line-level text detection и OCR error detection.

Пример

from PIL import Image
from surya.inference import SuryaInferenceManager
from surya.recognition import RecognitionPredictor

manager = SuryaInferenceManager()
rec = RecognitionPredictor(manager)
predictions = rec([Image.open(IMAGE_PATH)])
ПодробнееБенчмарки: 85.9 OmniParseBench, 83.7% olmOCR-bench, 74.9% на внутреннем наборе из 91 языка.
Скорость: 4.5 стр./с на H100 при 192 DPI; 1.7× быстрее Surya 2 с MTP.
Запуск: нужен vllm на NVIDIA GPU (Docker + NVIDIA Container Toolkit) или llama.cpp на CPU/Apple Silicon.
Лицензия весов: modified AI Pubs Open Rail-M — бесплатно для исследований, личного использования и стартапов с финансированием/выручкой до $5M.
Ограничение: геометрия строк и колонок таблиц требует checkpoint Surya 2.
Примеры
Discuss Telegram 40 15K

Will it run?

Working out the memory needs

The bot is still collecting this model's weight sizes; the estimate will appear here in a few minutes. Meanwhile you can rent a GPU with headroom.

Massed ComputeOpen Massed Compute

Run it on Massed Compute

The script downloads the model to the rented machine. How to run it is in the model card.

  1. 1. Rent a machine with a fitting GPU

    Open Massed Compute
  2. 2. Paste the script into the machine's terminal

    Connect over SSH (the Massed Compute panel shows the command) or open a terminal on the machine's desktop.

    HF_TOKEN / CIVITAI_TOKENThe script starts with token lines: paste yours between the quotes. The Hugging Face token is for gated models, the Civitai one for Civitai models.

    # datalab-to/surya-ocr-2.5
    mkdir -p ~/models
    curl -LsSf https://astral.sh/uv/install.sh | sh
    source "$HOME/.local/bin/env"
    uv tool install "huggingface_hub[cli]"
    hf download datalab-to/surya-ocr-2.5 --local-dir ~/models/surya-ocr-2.5
    # The model is in ~/models. How to run it is in the model card (link above).
    Add more LoRAs to surya-ocr-2.5
  3. 3. Use it

    The model is in ~/models. How to run it is in the model card (link above).

Stop the machine in the panel when you are done: it bills by the minute while it runs.

How to speed it up

Picked for this model type. Choose your hardware above to see what fits you exactly.

  • FlashAttention 44.0.0b40from November 18, 2026new release

    fastest exact attention on B200

    Kernels for Blackwell (beta). Exact attention without quantisation — fine for everything, LLMs included.

    How to enable: pip install flash-attn-4; vLLM and SGLang pick it up themselves.

    Earlier generations (2)
    • FlashAttention 3 — The Hopper (H100/H200) version with FP8.
    • FlashAttention 2 — The standard for RTX 30/40/50 and A100: exact attention without the memory cost of long contexts.
  • torch.compile2.15.0from October 28, 2026new release

    10–30% for free

    Compiles the model for your GPU. Slower first run, faster afterwards.

    How to enable: model = torch.compile(model); in ComfyUI the TorchCompileModel node.

Model family

New posts about versions of surya-ocr-2.5 (quants, finetunes, LoRAs) will show up under the bell.

No known relatives of this model yet. All derivatives on Hugging Face

About the model

datalab-to/surya-ocr-2.5
Author
datalab-to
Category
Computer vision
Released
Posted

On NeyroLearn

Hugging Face

15K40

Ask AI about this model

Answered by Gemini 4 · the chat is kept only in this tab

Comments

Computer vision

OvisOCR3

OvisOCR3