Marker: PDF-to-Markdown that refuses to choose between speed and accuracy
A document converter that routes clean pages to CPU and hard pages to a small VLM, so you get near-VLM accuracy at pipeline throughput.

What it does
Marker converts PDFs, images, Office files, EPUB, and HTML into Markdown, JSON, HTML, and chunks — handling tables, equations, inline math, links, and code blocks, while stripping headers, footers, and other artifacts. It runs on GPU, CPU, or Apple Silicon, and can optionally bring in an LLM (Gemini, Claude, OpenAI-compatible, Ollama, etc.) for the fiddly stuff like merging tables across pages. It’s the tool you reach for when a PDF needs to become something an LLM pipeline can actually consume.
The interesting bit
The balanced mode is the clever part: instead of running a vision model on every page, it keeps clean Latin prose on CPU (pdftext + in-process Indra ONNX layout) and only escalates equations, complex tables, CJK scripts, and scans to the 0.69B Surya 2.5 VLM. That hybrid routing is how it claims to beat larger open VLMs on accuracy while running 14–21× faster.
Key highlights
- Four modes spanning hardware tiers:
no_ocr(57 pg/s, CPU-only),fast(23.6 pg/s, ~18 MB ONNX weights, no GPU needed),balanced(16.9 pg/s, GPU default), andvllm(85.9 OmniParseBench, full VLM on every page) - On OmniParseBench (16,288 pass/fail tests over 2,937 pages, 92 languages),
balancedscores 80.5 vs docling’s 67.5 at 8× the speed - Handles 92 languages, multi-column layouts, forms, and inline math → LaTeX
- Extensible with your own formatting and logic; built-in interactive web viewer for inspecting layout blocks and reading order
- Apache 2.0 code; model weights are OpenRAIL-M (free for research, personal use, and startups under $5M funding/revenue)
Caveats
- GPU modes require a local Surya inference server (vLLM via Docker on NVIDIA, llama.cpp elsewhere) — auto-spawned, but it’s real infrastructure underneath
- The benchmarks are self-published against the authors’ own OmniParseBench dataset, so take the Pareto-frontier claims with the usual grain of salt
- Commercial use of the model weights beyond the startup threshold requires a paid license
Verdict
If you’re feeding documents into RAG or LLM pipelines and docling/Tesseract output has been letting you down, Marker is the obvious next step. If you only occasionally convert a clean, born-digital PDF, it’s more machinery than you need.
Frequently asked
- What is datalab-to/marker?
- A document converter that routes clean pages to CPU and hard pages to a small VLM, so you get near-VLM accuracy at pipeline throughput.
- Is marker open source?
- Yes — datalab-to/marker is open source, released under the Apache-2.0 license.
- What language is marker written in?
- datalab-to/marker is primarily written in Python.
- How popular is marker?
- datalab-to/marker has 41k stars on GitHub.
- Where can I find marker?
- datalab-to/marker is on GitHub at https://github.com/datalab-to/marker.