huggingface.co web signal

Baidu open-sources Unlimited-OCR-2 for 100-page documents

TL;DR

  • Baidu released Unlimited-OCR-2 on October 27, a 3B-parameter MIT-licensed model built to parse documents stretching past 100 pages in a single pass.
  • Its SR-SWA attention scheme compresses text-visual interactions into a fixed-size pool of reference tokens (512 in the release) to keep decoding cost nearly flat.
  • The model scores 77.1 on Baidu's new MarathonDocBench (100 to 300 page docs) and 84.6 on MPDocBench for shorter multi-page parsing.

Baidu has released Unlimited-OCR-2, a 3-billion-parameter document parser under an MIT license, built to read documents stretching into the hundreds of pages in a single inference pass rather than slicing them up beforehand.

The core trick is a sparse attention scheme the lab calls SR-SWA, short for Sparse Reference Sliding Window Attention. Instead of growing the key-value cache as pages roll in, SR-SWA compresses prior text and visual interactions into a fixed-size pool of reference tokens — 512 is the working size named in the release — paired with a 128-token local window and a top-16 selection over 32-token blocks. The model card's claim is that this gives "near-constant per-step decoding latency and memory footprint regardless of document length."

On MarathonDocBench, a long-document benchmark of 100 to 300 pages that Baidu introduced alongside the model, Unlimited-OCR-2 posts 77.1 overall. The next model listed, Kimi-K3, scores 33.7, and the comparison figures show Qwen3.8-Max falling from 78.3 on shorter inputs to 22.9 on the long set. On MPDocBench, which tops out closer to 30 pages, the model scores 84.6. The headline framing in the Hugging Face card is "One-shot Long-horizon Parsing" — meaning multi-page PDFs and image stacks go in as one call.

Baidu's launch post was blunter: "Longer documents can mean a lot more attention computation. Our new SR-SWA mechanism keeps that in check by condensing text-visual attention interactions into a fixed-size set of working references." A pair of researchers on our Who's Who radar circulated the release the day it dropped.

The repo ships inference recipes for Hugging Face Transformers, SGLang, vLLM and Docker Model Runner, with a lineage the write-ups trace to DeepSeek-OCR — notable given how much of the current open OCR cohort is building on top of DeepSeek's released work.

Shared on Bluesky by 2 AI experts