LightOnOCR-3 4B

LightOn · Document OCR
POST /v1/ocrDocument OCR that reads PDFs and images into structured Markdown, page by page, with tables, math, charts, image regions, and layout.
At a glance
Pricing
Example request
Parameters
Notes
Reads PDFs and images into Markdown, page by page: text in reading order, headings, lists, tables, math, captions, and charts with their data points as a table.
Input
- One PDF or image per request: PDF, PNG, JPEG, WebP, TIFF, BMP, GIF or AVIF, up to 50 MB, as a public URL or a base64 data URI.
- Up to 1,000 pages per request. Choose pages with
pages, zero-based, as a list such as[0, 2]or a string such as0,2-4. - Structured annotation fields are not supported.
Output
- Each page as Markdown, with the position of every image region and the page’s layout blocks in reading order.
include_image_base64returns each image region as a JPEG data URI.table_formatset tomarkdownorhtmlreturns each table separately; otherwise tables stay in the Markdown as HTML.extract_headerandextract_footermove headers and footers out of the Markdown into their own fields.
Long documents
- A request still running after about four and a half minutes returns a job id to poll at
GET /v1/jobs/{job_id}. SendPrefer: respond-asyncto get it at once.
Billing
- Billed per page read, with a minimum of 5 pages per request. A failed request is not billed for pages it did not return.
Weights
- FP8.
Machine-readable schema: GET https://api.empiriolabs.ai/v1/models/lightonocr-3-4b.
