Open Source
Explore the latest AI open-source projects from GitHub and HuggingFace.
Explore the latest AI open-source projects from GitHub and HuggingFace.
Unlimited-OCR is Baidu's open-source document parsing model, released on 22 June 2026 with the stated goal of pushing DeepSeek-OCR "one step further." In roughly five weeks it has reached about 19,700 stars and 1,931 forks, making it one of the fastest-growing vision models on GitHub this summer. The tagline — "Welcome the Era of One-shot Long-horizon Parsing" — describes the actual technical claim: parsing an entire multi-page document in a single pass rather than page by page. ## The Long-Horizon Problem Most OCR pipelines treat a document as a bag of independent pages. Each page is cropped, fed to a model, and the outputs are stitched back together afterwards. That works until the document has structure that spans pages — a table continuing across a page break, a footnote reference resolved three pages later, a section heading that governs everything below it. Unlimited-OCR's design target is the opposite: feed the model many pages at once and let it parse them as one continuous context. The `infer_multi` entry point takes a list of page images and a `Multi page parsing.` prompt, and returns a single structured output for the whole run. The model works within a 32,768-token context, and the repository ships a PyMuPDF helper that rasterizes a PDF at 300 DPI and hands the resulting page list straight to `infer_multi`. This is a genuinely different framing from page-at-a-time OCR, and it is where the project's name comes from. Whether it holds up on very long documents is the practical question a team should test on its own corpus before committing. ## Two Resolution Modes Single-image inference exposes two configurations. `gundam` runs `base_size=1024` with `image_size=640` and `crop_mode=True`, tiling the page into crops — the higher-fidelity path for dense pages. `base` runs a flat `image_size=1024` with cropping disabled, which is faster and is the only mode supported for multi-page and PDF parsing. That asymmetry matters when planning a deployment: the long-horizon mode you would want for a 200-page report is also the lower-resolution one. Dense financial tables may still be better served by per-page `gundam` runs, and the repository gives you both without forcing a choice. Generation uses an aggressive repetition guard — `no_repeat_ngram_size=35` with an `ngram_window` of 128 for single images and 1,024 for multi-page runs. Repetition collapse is a known failure mode for OCR-style autoregressive decoding on repetitive layouts, and the parameters are surfaced rather than buried. ## Deployment Paths The project did not stay a research drop. Within a month it picked up serving support across the main inference stacks: Hugging Face `transformers` works out of the box with `trust_remote_code=True` and bf16 weights on a CUDA device. vLLM support landed on 28 June via a community contribution, with an official recipe at recipes.vllm.ai and prebuilt images (`vllm/vllm-openai:unlimited-ocr`, plus a CUDA 12.9 variant for Hopper). SGLang is supported through a bundled wheel and a launch command with a custom logit processor that carries the same no-repeat n-gram logic into the serving path — notably reusing DeepSeek-OCR's processor class, an honest signal about the lineage. An `infer.py` batch script starts the SGLang server itself and fans concurrent requests across an image directory or PDF. Beyond that, the model is on ModelScope, has a Hugging Face Space demo, is trainable via ms-swift as of 21 July, and is available as a managed endpoint on Baidu Cloud. For a five-week-old release, that is unusually broad coverage. ## Output Format and Evaluation Output is emitted with inline `<|det|>type [bbox]<|/det|>` markers, so text comes back with layout category and bounding-box coordinates attached rather than as a flat string. That is useful if you are building a downstream layout-aware index; it is extra work if you just want text. The README includes a `remove_det` post-processing function that strips the markers and regroups lines into blocks — required for OmniDocBench evaluation, and a reasonable starting point for plain-text extraction. The accompanying paper is on arXiv (2606.23050), authored by a seventeen-person Baidu team. ## Pros and Cons The strengths are real. MIT licensing on a model from a major lab is permissive by the standards of the category. Multi-page single-pass parsing addresses a structural weakness in existing pipelines rather than chasing a benchmark delta. Serving support across transformers, vLLM, and SGLang means production deployment does not require custom glue. Bounding-box output preserves layout information most OCR tools discard. And the acknowledgements openly credit DeepSeek-OCR, DeepSeek-OCR-2, and PaddleOCR rather than presenting the work as sui generis. The caveats deserve equal weight. The README publishes no benchmark table — it explains how to run OmniDocBench evaluation but does not report results, so the "one step further" claim is unquantified in the repository itself and you must go to the paper or measure it yourself. Multi-page parsing is locked to the lower-resolution `base` mode. Inference is CUDA-oriented throughout, with no CPU or Apple Silicon path documented. The SGLang route requires installing a bundled dev wheel rather than a released version. Sixty-nine open issues against a project this young is normal but signals rough edges. And the model card does not document which languages are covered to what standard, which matters for a document parser. ## Outlook Document parsing has become one of the more contested areas of open vision modeling, with DeepSeek-OCR, PaddleOCR, MinerU, and surya all competing for the same RAG-ingestion workloads. Unlimited-OCR's bet is that context length, not per-page accuracy, is the next axis of improvement — that a model which sees the whole document beats one that sees the best possible single page. If that thesis holds, the approach generalizes; if long-context degradation proves worse than page-level stitching error, it does not. The rapid uptake by vLLM, SGLang, and ms-swift suggests the inference community finds the bet credible enough to build on. ## Conclusion Unlimited-OCR is worth evaluating if you are ingesting long structured documents — reports, filings, manuals — where cross-page structure carries meaning and page-at-a-time OCR is losing it. The MIT license and broad serving support lower the cost of trying it. Teams needing CPU inference, published accuracy numbers before adoption, or maximum fidelity on individual dense pages should benchmark it against DeepSeek-OCR and PaddleOCR on their own documents rather than switching on the strength of the framing.