Standard vs VLM pipeline#
| Standard pipeline | VLM pipeline | |
|---|---|---|
| How | Parser + layout model + TableFormer + OCR | One vision-language model per page image |
| Uses the PDF's own text | Yes — exact characters from born-digital PDFs | No — the model reads the rendered page |
| Speed on CPU | 2.3 s/page in our test (OCR off) | Granite-Docling took 310 s for a 2-page excerpt in our test (model load included) — plan for a GPU or Apple Silicon |
| Strengths | Fast, faithful text, bounding boxes for every item | Formulas, code, charts, odd layouts; one model to deploy |
| Risks | Complex tables can merge rows (see our table test) | Generative errors: skipped or repeated text, especially on long pages |
Run it#
pip install "docling[vlm]"
docling convert report.pdf --pipeline vlm # default preset: granite_docling
docling convert report.pdf --pipeline vlm --vlm-model smoldocling
docling convert report.pdf --pipeline vlm --to html_split_page --show-layoutfrom docling.datamodel.base_models import InputFormat
from docling.datamodel.pipeline_options import VlmConvertOptions, VlmPipelineOptions
from docling.document_converter import DocumentConverter, PdfFormatOption
from docling.pipeline.vlm_pipeline import VlmPipeline
opts = VlmPipelineOptions()
opts.vlm_options = VlmConvertOptions.from_preset("granite_docling")
converter = DocumentConverter(format_options={
InputFormat.PDF: PdfFormatOption(pipeline_cls=VlmPipeline, pipeline_options=opts)
})
doc = converter.convert("report.pdf").document
print(doc.export_to_markdown())VlmConvertOptions.list_presets() returns every preset with its model and description; from_preset() is exactly what the CLI calls for --vlm-model.
Granite-Docling-258M in brief#
- Made by: IBM Research · licence: Apache 2.0 · released: 17 September 2025.
- Architecture: Idefics3 design with a
siglip2-base-patch16-512vision encoder and a Granite 165M language model. - Output: DocTags — compact markup for layout, text, tables, code, formulas and charts that maps onto a DoclingDocument.
- Languages: English; Japanese, Arabic and Chinese are marked experimental.
- Prompts: “Convert this page to docling.” for full pages; short instructions such as “Convert chart to table.” for single elements.
Source: ibm-granite/granite-docling-258M model card
Show data table
| SmolDocling-256M-preview | Granite-Docling-258M | |
|---|---|---|
| Layout F1 | 0.85 | 0.86 |
| Layout recall | 0.84 | 0.88 |
| Layout precision | 0.9 | 0.92 |
| MMStar | 0.17 | 0.3 |
| OCRBench ÷ 1000 | 0.338 | 0.5 |
All 22 presets#
Read from VlmConvertOptions.list_presets() in Docling 2.143.1. “Remote code” presets only run with --trust-remote-code — review the model's code first.
VlmConvertOptions.list_presets(), read by docling.org.
Show data table
| Billion parameters | |
|---|---|
| smoldocling | 0.26B |
| granite_docling | 0.26B |
| falcon_ocr | 0.30B |
| nemotron_parse_v3_5 | 0.60B |
| nemotron_parse_v2 | 0.90B |
| glm_ocr | 0.90B |
| lightonocr | 1.00B |
| mineru2_pro | 1.20B |
| granite_vision | 2.00B |
| deepseek_ocr | 3.00B |
| qwen | 3.00B |
| nanonets_ocr2 | 3.00B |
| dots_ocr | 3.00B |
| dots_mocr | 3.00B |
| unlimited_ocr | 3.34B |
| chandra_ocr2 | 5.30B |
| pixtral | 12.00B |
| gemma_12b | 12.00B |
| gemma_27b | 27.00B |
--vlm-model | Model | Size | Output | Notes |
|---|---|---|---|---|
granite_docling | ibm-granite/granite-docling-258M | 258M | DocTags | Default · MLX build |
smoldocling | docling-project/SmolDocling-256M-preview | 256M | DocTags | Predecessor · MLX build |
falcon_ocr | tiiuae/Falcon-OCR | 0.3B | Markdown | Remote code · MLX |
glm_ocr | zai-org/GLM-OCR | 0.9B | Markdown | MLX |
lightonocr | lightonai/LightOnOCR-2-1B | 1B | Markdown | MLX |
mineru2_pro | opendatalab/MinerU2.5-Pro-2604-1.2B | 1.2B | MinerU two-step | Transformers, MLX, API |
granite_vision | ibm-granite/granite-vision-3.3-2b | 2B | Markdown | Transformers, vLLM, Ollama, LM Studio |
deepseek_ocr | deepseek-ocr:3b | 3B | Markdown | Via Ollama or LM Studio only |
qwen | Qwen/Qwen2.5-VL-3B-Instruct | 3B | Markdown | MLX |
nanonets_ocr2 | nanonets/Nanonets-OCR2-3B | 3B | Markdown | MLX |
dots_ocr | rednote-hilab/dots.ocr | 3B | JSON with boxes | Remote code |
dots_mocr | rednote-hilab/dots.mocr | 3B | JSON with boxes | Remote code; needs flash-attn with Transformers |
unlimited_ocr | baidu/Unlimited-OCR | 3.34B MoE | Markdown with boxes | |
chandra_ocr2 | datalab-to/chandra-ocr-2 | 5.3B | HTML with boxes | Remote code · MLX |
pixtral | mistral-community/pixtral-12b | 12B | Markdown | MLX |
gemma_12b | google/gemma-3-12b-it | 12B | Markdown | MLX only |
gemma_27b | google/gemma-3-27b-it | 27B | Markdown | MLX only |
phi4 | microsoft/Phi-4-multimodal-instruct | — | Markdown | Remote code · Transformers, vLLM |
got_ocr | stepfun-ai/GOT-OCR-2.0-hf | — | Markdown | Transformers |
dolphin | ByteDance/Dolphin | — | Markdown | |
nemotron_parse_v2 | nvidia/NVIDIA-Nemotron-Parse-2.0 | — | Nemotron Parse | Remote code · Transformers, MLX, vLLM |
nemotron_parse_v3_5 | nvidia/Nemotron-3.5-Parse | — | Nemotron Parse | Transformers, API |
“MLX only” and similar notes come from each preset's list of supported engines. Licences differ per model — check the model card before commercial use.
Choosing between standard and VLM#
- Start with the standard pipeline. It is the default for a reason: fast, exact text on born-digital PDFs, provenance for every element.
- Check the result visually.
--to html_split_page --show-layoutputs each page next to what Docling extracted. - Try Granite-Docling on the pages that fail. Combine with
--page-rangeto test a few pages before committing GPU time. - Compare on your own documents. Published scores are averages over other people's documents; ten of yours tell you more.
Picture descriptions and chart extraction#
You do not need the full VLM pipeline to use vision models. The standard pipeline can call a small VLM only for pictures:
docling convert report.pdf --enrich-picture-description # captions for figures
docling convert report.pdf --enrich-chart-extraction # bar/pie/line charts → tables
docling convert report.pdf --enrich-chart-extraction --chart-extraction-preset granite_vision_v4Chart extraction presets in 2.143.1: granite_vision_v3_3, granite_vision_v4 (default) and granite_vision_v4_mlx. The default resolves to IBM Granite-Vision-4.1-4B (ibm-granite/granite-vision-4.1-4b) and granite_vision_v3_3 to a 2B chart-to-CSV model — plan for a GPU or Apple Silicon. We checked these preset names against 2.143.1 but did not run chart extraction on our CPU test machine.
Frequently asked questions
What is Granite-Docling?
Granite-Docling-258M is a compact vision-language model from IBM Research, released on 17 September 2025 under Apache 2.0. It converts a page image into DocTags markup, which Docling turns into a DoclingDocument. It builds on the Idefics3 architecture with a SigLIP2 vision encoder and a Granite 165M language model.
How do I use Granite-Docling with Docling?
Install docling[vlm] and run docling convert file.pdf --pipeline vlm --vlm-model granite_docling. In Python, set VlmPipelineOptions().vlm_options = VlmConvertOptions.from_preset('granite_docling') and use VlmPipeline as the pipeline class.
Is the VLM pipeline better than the standard pipeline?
Not always. The standard pipeline is faster and very good on born-digital PDFs. A VLM can do better on complex layouts, formulas and code, and a single model is easier to deploy, but it is much slower without a GPU and can hallucinate or repeat text.
What replaced SmolDocling?
Granite-Docling-258M is the successor to SmolDocling-256M-preview and is the default VLM preset. The smoldocling preset is still available.
Can I run the VLM pipeline on a Mac?
Yes. Most DocTags and several Markdown presets have MLX builds that Docling uses automatically on Apple Silicon, for example ibm-granite/granite-docling-258M-mlx.
Sources
- ibm-granite/granite-docling-258M model card
- SmolDocling paper (arXiv 2503.11576) — DocTags
- Docling source: VlmConvertOptions presets (docling/datamodel)
- IBM announcement: Granite-Docling