Dramatically increased size of PDF after OCR

If anyone’s interested, here’s a smart rule script for automating PDF Squeezer compression:

on performSmartRule(theRecords)
	set theProfilePath to "[ path to .pdfscp file ]"
	tell application id "DNtp"
		repeat with eachRecord in theRecords
			
			set thePath to path of eachRecord
			set theResult to do shell script "/usr/local/bin/pdfs " & quoted form of thePath & " --replace --profile " & quoted form of theProfilePath
			if theResult is "" then add custom meta data 1 for "mdfilecompressed" to eachRecord
			
		end repeat
	end tell
end performSmartRule

Setup-wise, after installing the command line tool within the app, you just need to export your chosen PDF Squeezer settings as a .pdfscp file and add that path to the second line of the script. mdfilecompressed should be set up as boolean in your custom metadata.

The smart rule itself then looks something like this:

Of course, use at your own risk and test before doing any batch processing!