anaksor-ocr
Sokheng · Kit
Reads Khmer and English text from documents, receipts and photos of signs, using a detector for text lines and a recogniser for each line. Suits developers who…
Parses document images and multi-page PDFs into text with a 3.3B vision-language model from Baidu. For developers who add OCR and document parsing to their own tools.
Unlimited-OCR is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on . Download it on this page, a zip of its files. Nothing in it runs by itself.
torch==2.10.0 torchvision==0.25.0 transformers==4.57.1
Unlimited-OCR is a 3.3B-parameter image-to-text model from Baidu for reading documents. You give it a page image, several page images or a PDF turned into images, and it parses them into text. The authors present it as a step beyond Deepseek-OCR, and it runs through the transformers library.
It suits developers and teams who turn scanned pages and multi-page documents into text inside their own code.
| Industry | Who uses it | How they use it | Example |
|---|---|---|---|
| Finance and legal | Operations teams | Parse scanned multi-page documents into text | A stack of scanned contract pages read in one call |
| Publishing and archives | Archivists | Digitize page images | Old scans turned into searchable text |
| Software | Developers | Add document parsing to an app | A service that calls the model on each uploaded page |
| AI research | Researchers | Study long-document parsing | Compare its output with Deepseek-OCR on the same pages |
If you have no NVIDIA GPU, the transformers example here will not run as written, so you may want to skip it.
| Use case | Who | What they get back |
|---|---|---|
| Single page parsing | Developers | Text parsed from one image, saved to the output folder you name |
| Multi-page parsing | Document teams | Parsed text for several page images in one call |
| PDF parsing | Data teams | Parsed text for a PDF after its pages become images |
You need these first:
torch==2.10.0 torchvision==0.25.0 transformers==4.57.1 Pillow==12.1.1 matplotlib==3.10.8 einops==0.8.2 addict==2.4.0 easydict==1.13 pymupdf==1.27.2.2 psutil==7.2.2
pip install -U huggingface_hub hf download baidu/Unlimited-OCR
import os
import torch
from transformers import AutoModel, AutoTokenizer
model_name = 'baidu/Unlimited-OCR'
tokenizer = AutoTokenizer.from_pretrained(model_name, trust_remote_code=True)
model = AutoModel.from_pretrained(
model_name,
trust_remote_code=True,
use_safetensors=True,
torch_dtype=torch.bfloat16,
)
model = model.eval().cuda()After loading, call infer on one image, or infer_multi on several page images. A single image can use the gundam setting or the base setting. Several pages and PDFs use the base size only.
model.infer(
tokenizer,
prompt='<image>document parsing.',
image_file='your_image.jpg',
output_path='your/output/dir',
base_size=1024, image_size=640, crop_mode=True,
max_length=32768,
no_repeat_ngram_size=35, ngram_window=128,
save_results=True,
)| Tool | What it does |
|---|---|
| model.infer | Parses one image with the gundam or the base setting |
| model.infer_multi | Parses several page images in one call at image size 1024 |
| PDF route | Turns each PDF page into an image with PyMuPDF at 300 dpi, then calls infer_multi |
You pass three page images, page1.png to page3.png, to infer_multi with the multi-page prompt. The model parses them together and saves the results to the output folder you set.
This is an OCR model: it reads text out of pictures of pages. A first small thing to try is the Hugging Face Spaces demo, then the single-image example once the packages are installed.
Under the hood, gundam turns crop mode on at image size 640, while base turns it off at 1024. The examples set a maximum length of 32768 and a no-repeat n-gram size of 35, with a wider window for multi-page runs. The weights are BF16, and the 4-bit size is an estimate.
Weight size depends on precision, and the 4-bit figure is an estimate.
Parses document images and multi-page PDFs into text with a 3.3B vision-language model from Baidu. For developers who add OCR and document parsing to their own tools.
Made by baidu on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.
What it is: Unlimited-OCR is a 3.3B-parameter image-to-text model from Baidu for reading documents. You give it a page image, several page images or a PDF turned into images, and it parses them into text. The authors present it as a step beyond Deepseek-OCR, and it runs through the transformers library.
Who it suits: It suits developers and teams who turn scanned pages and multi-page documents into text inside their own code.
Industry | Who uses it | How they use it | Example
Finance and legal | Operations teams | Parse scanned multi-page documents into text | A stack of scanned contract pages read in one call
Publishing and archives | Archivists | Digitize page images | Old scans turned into searchable text
Software | Developers | Add document parsing to an app | A service that calls the model on each uploaded page
AI research | Researchers | Study long-document parsing | Compare its output with Deepseek-OCR on the same pages
If you have no NVIDIA GPU, the transformers example here will not run as written, so you may want to skip it.
Where to use it:
Use case | Who | What they get back
Single page parsing | Developers | Text parsed from one image, saved to the output folder you name
Multi-page parsing | Document teams | Parsed text for several page images in one call
PDF parsing | Data teams | Parsed text for a PDF after its pages become images
How to set it up: You need these first:
torch==2.10.0
torchvision==0.25.0
transformers==4.57.1
Pillow==12.1.1
matplotlib==3.10.8
einops==0.8.2
addict==2.4.0
easydict==1.13
pymupdf==1.27.2.2
psutil==7.2.2
pip install -U huggingface_hub
hf download baidu/Unlimited-OCR
import os
import torch
from transformers import AutoModel, AutoTokenizer
model_name = 'baidu/Unlimited-OCR'
tokenizer = AutoTokenizer.from_pretrained(model_name, trust_remote_code=True)
model = AutoModel.from_pretrained(
model_name,
trust_remote_code=True,
use_safetensors=True,
torch_dtype=torch.bfloat16,
)
model = model.eval().cuda()
How to use it: After loading, call infer on one image, or infer_multi on several page images. A single image can use the gundam setting or the base setting. Several pages and PDFs use the base size only.
model.infer(
tokenizer,
prompt='<image>document parsing.',
image_file='your_image.jpg',
output_path='your/output/dir',
base_size=1024, image_size=640, crop_mode=True,
max_length=32768,
no_repeat_ngram_size=35, ngram_window=128,
save_results=True,
)
Tool | What it does
model.infer | Parses one image with the gundam or the base setting
model.infer_multi | Parses several page images in one call at image size 1024
PDF route | Turns each PDF page into an image with PyMuPDF at 300 dpi, then calls infer_multi
Example: You pass three page images, page1.png to page3.png, to infer_multi with the multi-page prompt. The model parses them together and saves the results to the output folder you set.
For newcomers and experts: This is an OCR model: it reads text out of pictures of pages. A first small thing to try is the Hugging Face Spaces demo, then the single-image example once the packages are installed.
Under the hood, gundam turns crop mode on at image size 640, while base turns it off at 1024. The examples set a maximum length of 32768 and a no-repeat n-gram size of 35, with a wider window for multi-page runs. The weights are BF16, and the 4-bit size is an estimate.
Page images or PDF pages go in
A prompt tells the model what to parse
The model reads the pages on the GPU
Parsed results save to your output folder
Good to know: Weight size depends on precision, and the 4-bit figure is an estimate.
Title: Weight size by precision
BF16: 6.7 GB
4-bit estimate: 1.7 GB
Download its files with Hugging Face's command line:
pip install -U huggingface_hub
hf download baidu/Unlimited-OCR
Then follow the usage in its model card. Nothing in this kit runs by itself.
README.md 6 KB
Listed Hugging Face models in the same category that share the most tags with this one.
| Product | Downloads, last 30 days | Likes | Parameters | License | Last change |
|---|---|---|---|---|---|
| Unlimited-OCR This page | 5,833,292 | 5,004 | 3.3B | mit | |
| Unlimited-OCR-2Shares baidu · vision-language · multilingual | 519,371 | 684 | 3.3B | mit | |
| Unlimited-OCR-2-GGUFShares vision-language · multilingual · image-text-to-text | 8,452 | 8 | 2.9B | mit | |
| MiniCPM-OCR JevShares vision-language · image-text-to-text · conversational | 41,426 | 96 | 2.2B | apache-2.0 | |
| LightOnOCR-3-4BShares vision-language · image-text-to-text · conversational | 15,491 | 143 | 4.5B | apache-2.0 | |
| LightOnOCR-3-0.8BShares vision-language · image-text-to-text · conversational | 13,965 | 99 | 853M | apache-2.0 |
Posts and comments that name this project on Hacker News, Bluesky, X, Reddit, Facebook and YouTube, found by a weekly search and on Trendshift. Mindket doesn’t write or check them. Open one to read it where it was posted.
Sokheng · Kit
Reads Khmer and English text from documents, receipts and photos of signs, using a detector for text lines and a recogniser for each line. Suits developers who…
Qwen · Kit
Qwen2.5-7B-Instruct as GGUF files in eight quantization sizes, to chat with locally through llama.cpp. For people who want a capable 7.6B model on their own co…
ACE-Step · Kit
Generates music from text with a 4B diffusion decoder, 50 steps and guidance control, aiming for higher audio quality than the base. For creators with a GPU of…
alirezarezvani · Skill
Adds 411 ready-made skills for Claude Code and other coding agents, grouped by role from engineering and product to marketing, finance and compliance. Installs…
block · Kit
Self-hostable workspace where people and AI agents share the same rooms, built on a Nostr relay that logs every action as a signed event. For teams that want t…
backnotprop · Kit
Opens your AI coding agent's plans, specs and code changes in a browser so you can annotate or comment on them and send the feedback straight back to the agent.