Adaptive Coarse-to-Fine Visual Token Allocation for Multi-Page Dense Small-Text Recognition
A method that dynamically allocates high-resolution visual tokens only to dense document regions during multi-page parsing to eliminate small-text repetition errors.
Time
Compute level
Resources
What the paper used
Prerequisites
Scope
The Gap
While single-page evaluation uses DeepEncoder's dynamic-resolution Gundam mode, multi-page parsing relies exclusively on Base mode (1024x1024 compressed to 256 tokens per page) to keep prefix lengths tractable; in Section 5.4, Edit Distance on 40+ page documents rises to 0.1069 with repeated errors concentrated on small, hard-to-discern text.
“DeepEncoder natively supports five resolution modes; we retain two of them: the "Base" model (1024×1024 for multi-page), and the "Gundam" mode (dynamic resolution for single-page).”
Limitation
Uniformly compressing every page to 256 tokens in Base mode discards fine-grained legibility for dense layouts, footnotes, and small fonts in multi-page documents, triggering decoding repetition loops.
Proposed Solution
Introduce a two-tier visual encoding pipeline during prefill: encode all pages initially in Base mode (256 tokens) and run a lightweight text-density or high-frequency edge estimator on the SAM-ViT feature maps to flag pages or regions containing small or dense text. Selectively re-encode only flagged regions using Gundam-mode high-resolution crops spliced into that page's reference segment, preserving low average prefix token count while restoring character legibility.
Why This Matters
Selectively upgrading dense regions could substantially lower Edit Distance and repetition failures on 40+ page academic papers and newspapers without incurring the prohibitive token budget of running Gundam mode on every page.
How to Get Started
How to test it: Test the hypothesis that upgrading the top 20% densest pages in multi-page inputs from Base to Gundam crops reduces 40+ page Edit Distance from 0.1069 toward single-page levels (<0.06) while increasing total prefill tokens by less than 40%. Benchmark against uniform Base-mode Unlimited OCR on concatenated dense newspaper and academic paper sets, stopping if repetition rate (1 minus Distinct-35) does not significantly improve.
- Run the released Unlimited-OCR checkpoint in Base mode on dense multi-page subsets of OmniDocBench (such as Newspaper and Academic Paper) concatenated to 20-40 pages and log pages with Edit Distance above 0.10 or low Distinct-35.
- Measure the upper-bound accuracy recovery by re-running those failed pages individually in Gundam mode to quantify how much error stems purely from Base resolution.
- Design a lightweight heuristic or classifier over SAM-ViT patch features to trigger Gundam tiling only on dense or small-font pages.
- Fine-tune the released decoder with mixed Base-and-Gundam multi-page sequences on 4-8 GPUs and evaluate the Edit Distance versus prefill-token Pareto frontier.
Suggested by AI. Adapt it to your setup.
Has This Been Done?
Papers such as mPLUG-DocOwl2: High-resolution Compressing for OCR-free Multi-page Document Understanding and DeepSeek-OCR handle high-resolution visual token compression for document parsing. They do not, however, combine an edge/text-density estimator with selective high-resolution crop re-encoding in a two-tier coarse-to-fine pipeline as proposed.
- mPLUG-DocOwl2: High-resolution Compressing for OCR-free Multi-page Document Understanding · 2025 · 190 citations
- DeepSeek-OCR: Contexts Optical Compression · 2025 · 409 citations
We searched OpenAlex and arXiv for “adaptive resolution visual token compression multi-page document OCR” and “Adaptive Coarse-to-Fine Visual Token Allocation for Multi-Page Dense Small-Text Recognition” and an AI compared the idea with the top 10 results. A small search can miss relevant work.
Source Paper
Unlimited OCR WorksYouyang Yin, Huanhuan Liu, YY +14 more · 2026
Unlimited OCR addresses the memory and latency bottlenecks of long-horizon end-to-end document parsing, where standard LLM decoders accumulate linearly growing KV caches across dozens of pages. The authors introduce Reference Sliding Window Attention (R-SWA), enabling one-shot multi-page transcription with constant decode-side KV cache memory and generation speed while achieving state-of-the-art accuracy on OmniDocBench.
Related Ideas
- Dynamic Content-Aware Compression for High-Density LayoutsDeepSeek-OCR: Contexts Optical Compression🟠Medium
- Long-Context Hierarchical Heads and Retrieval Wrappers for Fixed-Length Pretrained ModelsHuggingFace's Transformers: State-of-the-art Natural Language Processing🟡Fairly easy
- Multi-Granularity Visual Encoding for Small-Scale Document ElementsSmolDocling: An ultra-compact vision-language model for end-to-end multi-modal document conversion🟠Medium
- Dynamic Multi-Scale Layout AnalysisMinerU2.5: A Decoupled Vision-Language Model for Efficient High-Resolution Document Parsing🟡Fairly easy
- Global Context Injection for Local Crop DecodingMinerU2.5: A Decoupled Vision-Language Model for Efficient High-Resolution Document Parsing🟠Medium