After I migrated my Evernote notes to Joplin, I was missing the functionality to do a full text search in attachments. I got inspired by a post on this forum:
After having a look on how rest-uploader does OCR, I decided to write a script which could add OCR text in existing Joplin notes.
The ocr-joplin-notes script can read notes from Joplin via the web clipper interface, OCR any image or PDF and insert the text as a comment block in the note. In case of a PDF document, it can also add a preview image.
The script has a simple detection algorithm to skip notes it suspects where created by rest-uploader and the notes it already processed. The current version of this script requires a tag to be supplied on the command line. It will only process the notes with that specific tag. Once all notes with that tag have been processed, the script will terminate. More details can be found in the readme.
The ocr-joplin-notes script is written in Python and has been tested on Ubuntu.