Import & OCR Rule doesn't seem to work

I have set up the “Import & OCR” Rule according top your blog post, but it doesn’t seem to work: When I add scanned PDFs or images to the indexed folder ToDtk, they stay in there and no searchable PDF is created from it.

Here my the rules scxreen of the Smart Rule:

DEVONthink sees the incomning files, beacuse the are listed in the smart rule view:

but nothing happens with these two documents.

The way I understand the Smart Rule, I expect that an OCR-ed PDF is created and moved into the Inbox.

But when I for example search for name:Scan_2024-03-03-001 I only find the orginal PDF. Same is true for the image file.

What goes wrong here?

Does the same smart rule which is available in the support assistant work as expected? At least it does over here.

I think, it is the rule from the assistant. I just changed the Search-In group and added the Move-to action.

Can you recheck your rule, because it doesn’t make logical sense to me (I’ve not run it so I can’t confirm if it works). You’ve said that a document has to be kind=image and kind=PDF, which is impossible (note at the top you’ve said “all” of the following has to be true, then set two different kind options within that).

2 Likes

I just checked the Rule and as I understand it, the rule says:

Item indexed and (Kind is image or (Kind is PDF and word count == 0)))

Were those documents already present in that group when you targeted it with the smart rule?

Maybe… Let me take them out and put them back in…

You’d need to do it in the Finder if they’re indexed files.

Yes, that was it! I moved the documents out of and (after the system had caught up on the change) back into the ToDtk folder and - voila - now the rule kicked in!

Thanks for your help!


PS: I must have changed the Search-In group of the rule to ToDtk after I had moved the documents in.

You’re welcome and do you see the simple logical error you made?

The items were already in the folder/group so there would be nothing to trigger the On Import event trigger.

Yes, of course! Moving/copying a file to the Indexed Folder is by DEVONthink seen as Import, righ?

Well, that’s exactly want I want from now on. :smile:

1 Like

Interesting, like edge versus level triggering in my world. :wink:

1 Like

What does that mean: Edge vs level triggering?

1 Like

My bad, my slang was a little arcane.

In electronics, a latch that is set (triggered) by the fact a signal changes is called edge triggering.

A latch that is set by the state of a signal is level triggered.

Generally, a positive level triggered flip-flop’s output will follow its input as long as the triggering signal is positive.

A positive edge triggered flip flop captures the input state on the transition. Once the edge occurs, the output is set. Further changes on the input are ignored until the next positive-going edge.

Edge triggered flip-flops take a snapshot on the edge. Level triggered follow the input while the trigger signal is valid.

1 Like