Transformers

Extract Text (OCR)

Reads the text out of an image with Apple's Vision framework — entirely on this Mac, no network, no AI provider.

transformer.extract_text_ocr
TRANSFORMExtract Text (OCR)

At a glance

Takes
An image path on the payload
Emits
extractedText, ocrConfidence, ocrLineCount, success
Good for
Screenshots, receipts, scanned pages, anything with words in it

Set it up

Point Image Path at the upstream file — {{filePath}} from a Photo Added or Directory Changed trigger, or any image path on the payload. The recognized text is merged onto the payload, so a later node can still act on the image itself.

The inspector for Extract Text (OCR): the image, how carefully to read it, and where the text lands.
The inspector for Extract Text (OCR): the image, how carefully to read it, and where the text lands.

Configure

FieldDefaultWhat it does
Image Path{{filePath}}The image to read.
Recognition LevelAccurateFast trades accuracy for speed.
Language CorrectionOnDictionary-based correction. Turn it off for codes, SKUs and serial numbers, where correction hurts.
Output KeyextractedTextWhere the recognized text lands.

Output

Every key is available downstream as {{key}}.

KeyTypeValue
extractedTextStringThe recognized text. Renamed by Output Key
ocrConfidenceNumberAverage per-line recognition confidence
ocrLineCountNumberHow many lines were recognized
successBooleanfalse when the image was missing, blocked, or still in iCloud
errorStringOn failure only — which of those it was

Example: read a screenshot

Input picks an image file. Extract Text (OCR) reads it. Log prints {{extractedText}}.

Three nodes: pick an image, read it, log the words.
Three nodes: pick an image, read it, log the words.

Paste this into the Flow Builder to get the same flow:

Let me pick an image with an Input trigger, run OCR on it, and log the text it found.

Good to know

A failure is a payload, not a stopped run. A missing file, a denied Photos permission, or an iCloud original that isn't on this Mac yet all come back as success: false with an error — branch on it with a Condition rather than expecting the flow to halt. A transient iCloud failure is also marked transient: true.

Photos access must be full. With Photos set to Limited rather than Full Access, the node refuses before any recognition runs, so a partial library can't quietly return nothing.

A photo whose bytes are still in iCloud is downloaded first when the payload carries its assetIdentifier, so the text comes from the original rather than a degraded copy.