用二维光学映射压缩长文本上下文,实现高精度文档识别。
DeepSeek-OCR: Contexts Optical Compression
- 通过2D光学映射将长文本转为低维视觉特征,保持低激活与高压缩比。
- 压缩比10倍时识别准确率达97%,20倍时仍保持60%准确率。
- 适合历史文档压缩、大模型记忆机制研究及大规模数据生成。
我们提出DeepSeek-OCR,初步探索通过二维光学映射压缩长上下文的可行性。该模型由DeepEncoder和DeepSeek3B-MoE-A570M解码器组成。其中,DeepEncoder作为核心引擎,在高分辨率输入下维持低激活,并实现高压缩比,确保视觉标记数量可控。实验表明,当文本标记数不超过视觉标记数的10倍(即压缩比<10x)时,模型可达到97%的解码(OCR)精度;即使在20x压缩比下,OCR准确率仍保持约60%。这为历史长上下文压缩与大模型记忆遗忘机制研究提供了显著潜力。此外,DeepSeek-OCR具备高实用价值:在OmniDocBench上,仅用100个视觉标记即超越GOT-OCR2.0(256标记/页),且在平均每页超过6000标记的MinerU2.0基准上表现更优,仅使用少于800个视觉标记。在生产环境中,单张A100-40G可每日生成20万+页的大模型/多模态模型训练数据。代码与模型权重已在http://github.com/deepseek-ai/DeepSeek-OCR公开。
原文摘要 · Abstract (English)
We present DeepSeek-OCR as an initial investigation into the feasibility of compressing long contexts via optical 2D mapping. DeepSeek-OCR consists of two components: DeepEncoder and DeepSeek3B-MoE-A570M as the decoder. Specifically, DeepEncoder serves as the core engine, designed to maintain low activations under high-resolution input while achieving high compression ratios to ensure an optimal and manageable number of vision tokens. Experiments show that when the number of text tokens is within 10 times that of vision tokens (i.e., a compression ratio < 10x), the model can achieve decoding (OCR) precision of 97%. Even at a compression ratio of 20x, the OCR accuracy still remains at about 60%. This shows considerable promise for research areas such as historical long-context compression and memory forgetting mechanisms in LLMs. Beyond this, DeepSeek-OCR also demonstrates high practical value. On OmniDocBench, it surpasses GOT-OCR2.0 (256 tokens/page) using only 100 vision tokens, and outperforms MinerU2.0 (6000+ tokens per page on average) while utilizing fewer than 800 vision tokens. In production, DeepSeek-OCR can generate training data for LLMs/VLMs at a scale of 200k+ pages per day (a single A100-40G). Codes and model weights are publicly accessible at http://github.com/deepseek-ai/DeepSeek-OCR.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。