Unlimited OCR Works is a high-performance, visual pipeline that bridges Baidu's state-of-the-art Unlimited-OCR (via Hugging Face Gradio API) and local Ollama LLMs (llama3.2:1b) to transcribe and instantly structure documents into clean Markdown.
The entire logic is compiled into a single file of under 100 lines of code (app.py), achieving maximum efficiency with zero fluff.
- 🎯 Precise OCR: Uses Baidu's Unlimited-OCR model for detailed document transcription.
- 🧠 Local LLM Structuring: Post-processes raw OCR outputs locally with Ollama (configured to use fast models like
llama3.2:1bwiththink=false). - 🎛️ Streamlit Dashboard: A native Web UI featuring a side-by-side layout, image visualization, and instant status monitoring.
- 📝 Automated Output saving: Writes parsed tables directly to
output.mdon every run.
- Core Engine:
gradio_client(Baidu Space connection) - Structuring:
ollama(Official Python SDK client) - Frontend:
streamlit(UI rendering) - Image handling:
pillow(mock receipt builder)
pip install -r requirements.txtMake sure the local Ollama server is running and the model is downloaded:
ollama run llama3.2:1bstreamlit run app.py📂 Unlimited OCR
├── 📄 app.py # Consolidated frontend and pipeline (<100 lines)
├── 📄 requirements.txt # Minimal dependencies list
├── 📄 output.md # Dynamically saved pipeline result
└── 📄 README.md # System documentation📋 1. Invoice & Receipt Parsing
Automatically extracts financial receipts, totals, tax, server, and quantities directly into a searchable database.📚 2. Academic & Multi-column Parsing
Handles complex layouts (multi-column text, annotations, footers) and structures them sequentially.🏥 3. Medical Report Structuring
Parses unstructured legacy lab results and scanning logs into standard clinical reports.📦 4. Logistics & Manifest Auditing
Converts raw warehouse logs, shipping slips, and packaging details into auditable cargo manifests.🏛️ 5. Historical Archive Search
Processes old print archive scans, cleaning up syntax anomalies and archaic spelling via the local LLM.- Offline OCR Execution: Fallback to local execution of Unlimited-OCR model if local CUDA device exists.
- PII Redaction: Auto-mask sensitive data (emails, credit cards, phones) before passing text to the LLM.
- Custom JSON Schema: Custom output schema constructor in the Streamlit UI.
Unlimited-OCR, Ollama OCR, Local LLM OCR, Streamlit OCR, Baidu Unlimited OCR, Free Document Parsing, Python OCR Pipeline, Gradio Client OCR