Automating messaging app replies

Type a Keystroke Action (v11.0.3)

Type a Keystroke.kmactions (541 B)

Keyboard Maestro Export
Hi, I'm trying to set up Keyboard Maestro to filter messages from apps like Messenger, Skype, etc. for specific keywords and trigger an automatic reply based on those messages.

The macro I upload here doesn't work, and I think the issue is because I failed the keyword detection part (Screen Capture, OCR System Clipboard).

Can anyone please point out where I did wrong? Or is there a better approach for this task?

Any input would be wonderful, thank you!



Unless you are also doing other things with the image you can miss out the screen capture and OCR directly. And try using "Apple Text Recognition" instead, as the Tesseract Engine that lies behind the other options is causing problems for some.

For troubleshooting, follow your OCR with a "Display text" so you can easily view what has (or hasn't!) been captured.

image

Text recognition can sometimes have problems with numbers and abbreviations -- "elephant" will be in the dictionary so can be inferred from a near-match, but "15h" might be read as "ish" -- so you might have try a more properly text-based method like Copying the contents of the window and searching that.