I finally gave up and found a better, faster, and more reliable alternative, and that's to use an auto-login to scp the clipboard file to the PC, where processing can take place.
Setting up scp to auto-login is pretty simple. It involves creating a keypair and moving the private key to the iPhone, then logging in to the computer with that key. Here is a more detailed guide.
Once the auto-login is set up, use this script on the iPhone:
scp -i ~/.ssh/KEY ~/Library/Preferences/com.hitoriblog.pasteboardstacker.plist USERNAME@IPADDRESS:/PATH/TO/PUT/THE/FILE
Now you can do the text processing on the computer. I will tweak that soon-tomorrow if I have the time- and post the results.