Unlimited OCR 2 speeds up parsing of extremely long documents
Unlimited OCR Works 2
Computation and LanguageComputer Vision and Pattern Recognition
Summary
Reading and understanding very long documents, such as hundreds of pages, is difficult for computers because their memory and processing needs grow a lot. The authors improved a previous system to make it focus only on the part it's currently reading, using a smart attention method that keeps computing time steady no matter how long the document is. This lets computers quickly process huge documents all at once without slowing down or needing huge memory. Their method was tested on specially created benchmarks for long documents, showing much faster speeds and better accuracy.
What this means in practice
- •For enterprise it teams: Process and extract text from lengthy business documents rapidly without heavy computing resources.
- •For digital archiving services: Digitize and transcribe large collections of scanned books or reports efficiently while maintaining accuracy.
Authors
Shu Wei, Jingjing Wu, Qunyi Xie, Lingshu Zhang, Xiangcheng Du, Yannian Fu, Mengjie Wang, Zuyi Wang, Zhichao Liu, Yangliu Xu, YY, Yi Yang
Abstract
Unlimited OCR ushers the era of long-horizon parsing, substantially mitigating the growth of working memory as document lengthens. However, as document length scales to hundreds of pages, the visual context grows substantially, sharply increasing the computational cost of each decoding step and limiting the scalability of ultra-long document parsing. Inspired by human book transcription via localized focus without re-scanning preceding pages, we introduce Unlimited OCR 2, a document parsing model that looks only at what it transcribes. Building on Unlimited OCR, we upgrade all the decoder attention modules to Sparse Reference Sliding Window Attention (SR-SWA), bounding active reference tokens to a fixed capacity and thus sustaining constant computational costs across arbitrarily long documents. By combining SR-SWA with Unlimited-Horizon Decoding Paradigm, Unlimited OCR 2 enables document parsing over virtually unlimited lengths without prohibitive memory overhead. At the hundred-page scale, Unlimited OCR 2 achieves 7.0$\times$ and 5.6$\times$ per-step speedups over Full Attention and R-SWA, respectively. Furthermore, it delivers state-of-the-art end-to-end performance on both MPDocBench and MarathonDocBench, our newly proposed benchmark targeting hundred-page document parsing. Ultimately, the capacity for uninterrupted, one-shot document parsing signifies a fundamental paradigm shift into the OCR 3.0 era.