Minimalist OCR macro not working to read from and write to clipboard

Looks like some weird bug in the Tesseract engine. I checked, and I get the same result as you, and checked that there was no encoding issue or such, the engine simply returns that garbled response after the first line.

It looks to be a bug, since it gets the first line right (as right as expected for OCR anyway), and if you chop out each line, it gets them right as well.

Tesseract is known to not be fond of white on black text, and indeed if you invert the text:

image

the OCR works fine. Unfortunately, Keyboard Maestro does not have any action that will invert images.