The proposed mechanism is polyphenols.
Historically, you'd get your polyphenols from your garden or wild gathering. But we know that industrial crops (even organic grown) have extremely low polyphenol content compared to their wild counterparts. So coffee remains as one of the few strong sources you can buy in a grocery store.
Hypothesis: Polyphenols from other sources would be just as protective as coffee.
That. Is. Fascinating. How'd you hear about the industrial crops having low polyphenol content?
> Coffee and tea contain bioactive ingredients like polyphenols and caffeine
There are also studies that nicotine lowers dementia risk.
Since caffeine and nicotine are both stimulants related to similar receptors, I wouldn't discount this other mechanism.
I'm not saying anything about general healthiness of caffeine though.