Open Source
Explore the latest AI open-source projects from GitHub and HuggingFace.
Explore the latest AI open-source projects from GitHub and HuggingFace.
LightOnOCR-3-4B is the largest model in LightOn's LightOnOCR-3 family of lightweight end-to-end OCR models, which turn document page images into text with layout and visual understanding in a single model rather than a multi-stage pipeline. It uses the Qwen3.5 vision-language architecture (Qwen3_5ForConditionalGeneration) in bfloat16, with about 4.54 billion parameters, a 32-layer text decoder that mixes linear-attention and full-attention layers (every fourth layer is full attention), a 24-layer vision encoder, and a configured maximum of 262,144 positions. LightOn describes it as its recommended model for most OCR tasks. The model has two prompt modes. With an empty prompt it returns the page text as markdown, which is the same behaviour as LightOnOCR-2, so existing integrations need no change. With the prompt grounding, each block is preceded by a label and a bounding box in page coordinates normalised to 0-1000; images receive a short description and charts are returned as an HTML table of their data points. Labels include text, title, list, header, footer, page_number, footnote, caption, formula, code, table, image, chart and aside_text. Grounding adds about 25 percent more output tokens, 1,433 versus 1,158 per page on average for the 4B. Other instructions are out of distribution, so only the empty prompt and grounding are supported. It targets tables, receipts, forms, charts, multi-column layouts and math notation. It runs with Transformers 5.2 or later (the checkpoint was saved with 5.5.4) or with vLLM, with thinking disabled, which is the chat template default. LightOn recommends rendering PDFs at 400 DPI and resizing to a longest edge of 2048 px with aspect ratio preserved. The family also includes a 1B variant that keeps the LightOnOCR-2 architecture and a smaller LightOnOCR-3-0.8B described as fast and efficient. All are released under Apache 2.0 for research and commercial use.