ocr
Extract text from image files or URLs using OCR, accurately transcribing printed, stylized, low-contrast, and multi-column content to provide verbatim text output.
Instructions
Process an image file or URL using OCR to extract text.
Uses EasyOCR for robust scene-text extraction. Excels at photos, signage, watermarks, logos, and printed text.
This is the right tool for any text in an image. EasyOCR handles both
of the cases that used to need separate routing -- dense printed text and
stylized, cursive, logo or low-contrast text -- so there is no longer a
reason to send the second kind to query_image, which paraphrases rather
than transcribing.
A page laid out in side-by-side columns (a form, meeting notes, a resume) is detected automatically: each column is OCR'd separately and joined in reading order, so fields from different columns don't get interleaved.
An image with no text returns an empty result, and that is the correct answer rather than a failure -- do not re-ask a captioning or VQA model to produce text for it, which is how invented text gets into a payload.
Set detail=true to get confidence scores and bounding boxes. This is
highly recommended for checking generative image artifacts: if an image
contains gibberish text, the confidence scores will drop significantly.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| src | Yes | Local file path or http(s) URL of the image to process. PDFs are also accepted and are rendered one image per page, so tools that return a list return one entry per page. | |
| detail | No | When true, return verbatim text *and* the bounding box and confidence score for each text span (via EasyOCR). Each page becomes a dict with `text_regions` ({text, confidence, box}[], box=[x1,y1,x2,y2] in page coordinates) and the joined `text`. Use this when you need to know *where* a phrase is, or to evaluate OCR confidence scores for anomaly detection. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |