DharmaOCR: Specialized Small Language Models for Structured OCR that outperform Open-Source and Commercial Baselines
arXiv cs.CL / 4/17/2026
📰 NewsDeveloper Stack & InfrastructureModels & Research
Key Points
- The paper introduces DharmaOCR Full (7B) and DharmaOCR Lite (3B), specialized small language models for structured OCR that jointly target transcription quality, stable generation, and low inference cost.
- It proposes DharmaOCR-Benchmark and a unified evaluation protocol that measures not only fidelity/structure but also text degeneration as a first-class metric, alongside unit cost.
- Using Direct Preference Optimization (DPO) for OCR with degenerate generations as rejected examples helps reduce degeneration rates (up to 87.6% relative) while maintaining or improving extraction quality.
- The models achieve new state-of-the-art results on DharmaOCR-Benchmark, scoring 0.925 (Full) and 0.911 (Lite) with very low degeneration rates (0.40% and 0.20%), and AWQ quantization cuts per-page cost by up to 22% with negligible quality loss.
- The study argues degeneration has real downstream production impact by increasing response time, reducing throughput, and inflating compute cost due to abnormally long generations, not just as an accuracy issue.
💡 Insights using this article
This article is featured in our daily AI news digest — key takeaways and action items at a glance.

![[Patterns] AI Agent Error Handling That Actually Works](/_next/image?url=https%3A%2F%2Fmedia2.dev.to%2Fdynamic%2Fimage%2Fwidth%3D1200%2Cheight%3D627%2Cfit%3Dcover%2Cgravity%3Dauto%2Cformat%3Dauto%2Fhttps%253A%252F%252Fdev-to-uploads.s3.amazonaws.com%252Fuploads%252Farticles%252Frn5czaopq2vzo7cglady.png&w=3840&q=75)


![[2026] OpenTelemetry for LLM Observability — Self-Hosted Setup](/_next/image?url=https%3A%2F%2Fmedia2.dev.to%2Fdynamic%2Fimage%2Fwidth%3D1200%2Cheight%3D627%2Cfit%3Dcover%2Cgravity%3Dauto%2Cformat%3Dauto%2Fhttps%253A%252F%252Fdev-to-uploads.s3.amazonaws.com%252Fuploads%252Farticles%252Flu4b6ttuhur71z5gemm0.png&w=3840&q=75)