Extract text from images
Optical Character Recognition (OCR) is a technology that converts different types of documents, such as scanned paper documents, PDF files, or images, into editable and searchable data.
Chunkr AI API always returns OCR results. You can configure the OCR strategy using the ocr_strategy
parameter.
We have two strategies:
All
(Default): Processes all pages with our OCR model.Auto
: Intelligently applies OCR only to pages with missing or low-quality text. When a text layer is present, the bounding boxes from that layer are used instead of running OCR.The Auto
strategy provides the best balance between accuracy and performance for most use cases.
Use the All
strategy when you need to ensure consistent text extraction across all pages or when you suspect the existing text layer might be unreliable.
OCR and Layout Analysis together are a powerful combination. It allows us to get word level bounding boxes and text while also understanding the layout of the document.
You can use that to make experiences like: