OCR and recognising purchase invoice dates

HI, I’m new to Devonthink and I’m struggling to get the dates to be recognised on the purchase invoices I’m bringing into DT. So at the moment I have started to store purchase invoices and I am either scanning them using a Scansnap IX500 or dragging or loading the .pdf and using the share button to send to DT. The problem I have (and this did work on one document) is that I want the created date to be the date on the invoice by picking up the first date (there’s only normally one date anyway on the docs) Any idea why this is working, as I said the first document I scanned in worked and the rest haven’t. Thanks in advance.

Could you provide more detail on how you are trying to do this? Then we’d be able to provide more insight on why it might not be working :wink:

Hi, thanks. So one way is I am loading up the .pdf and then using the share button to send to DT. The second way is the Scansnap is set to send directly to DT and thirdly I’ll drag the .pdf file directly form the mail message into DT. In the second two instances they are already .pdf files. All three methods seem to allow me to search across the files e.g. if Joe is in the file it finds it, so this seems to indicate it is running OCR on them - I think.

Ye-es, you had written as much; but none of those things would influence the created date of the record… are you using a smart rule, or just kinda hoping for magic? :wink: If the former, pls post a screenshot of the rule. If the latter, try using a smart rule. There’s lots of details in the handbook. Give it a go and report back with details if you get stuck.

1 Like

Well, there’s no guessing required. If the type of the document in the inspector pane says “PDF+Text”, there’s an OCR layer. If it’s “PDF” only, there’s no OCR layer.

Ah ok,
yea they all say pdf+text. I wasn’t aware of that as very new to DT. Thanks.

Thanks, No I’m not using a smart rule, I wasn’t aware of them. I figured because it worked on the first document I scanned (setting the creation date automatically) I didn’t need any rules. I’m confused by the fact it worked previously.

You may have chosen a setting in your scanner software which attempts to do the same thing. Of course that would only work when scanning, not when importing documents to DT in any other fashion. Try to set up a smart rule; your mileage may vary with regards the accuracy of detecting the document date, but the smart rule to do this is super simple. Take a look, because that is part of the learning process which will benefit you immensely when discovering what DT can actually do. But if you are not successful, post a screenshot of what you have got and I or one of the other folks here in the forum will point you in the right direction.

Thanks that’s really helpful. I do think it was the first document I scanned and that was using ScanSnap. Perhaps as you say that processes it different. I’ll certainly look at the smart rules and see how I get on.

1 Like

I’m not even sure it is, my own post sounds like “I’m not going to help you, go find out yourself” to me; it’s not meant that way, and you’ll get all and every assistance you need here. Discovering DT is a rewarding journey, and I think it’s a path worth going down. DT is far far more than a digital file folder. I have more than 50 smart rules, many with integrated scripts, automating handling of various documents. I had no idea of scripting before I settled down with DT, now some of the scripts are > 50 KB in size… (although I admit Applescript is pretty verbose). So play, and come back to report success, or failure.

1 Like

I would venture a guess this is true for many people here, myself included.
The most I ever ventured before DT was the odd Automator workflow to do something repetitive in the finder. Then last week I found myself looking up JXA vocabulary while customizing one of @chrillek’s scripts to do pretty much what @dkbold is trying to do (grab values from OCR text) and it was great to feel like I was taking a few small steps in learning to script. Reminiscent of when you can order coffee and a pastry in a new language and the barista doesn’t immediately switch to English to save everyone the awkwardness of hearing you butcher their language.

1 Like

I can relate to that – happened to me in Turkey all the time.

Thanks for the message, to be honest I get the impression folks on this forum are helpful. I’ll have a play around with it and see how I get on :grinning:

1 Like

We’re glad you’re getting that impression as that’s the tone and tenor we hope to always maintain in here :slight_smile:

That’s good to know. Thanks :blush:

1 Like