Lithium is a great example - very effective treatment for bipolar. No one really knows why. Prescribed for decades as they've tried to figure it out because tests showed it was effective and relatively safe, just no one knew exactly what it was doing in there.
It's sort of how you can be a woodworker without knowing the cellular biology of trees, and without being an electrical or mechanical engineer who can build a table saw from scratch.
Lithium-rich mineral springs have historically been touted for their healing properties. It was first used for mania in the late 1800s, with Denmark leading the way, but little was published about the medication for more than half a century.
https://www.verywellmind.com/lithium-the-first-mood-stabiliz...
I'm a believer in modern scientific medicine, but think we often have it backwards. Before reinventing the wheel we should exhaustively test what we used traditionally. Maybe the reason we don't do much of that is that it's not possible to patent, and so there's no financial incentive to do so?
https://pubmed.ncbi.nlm.nih.gov/?linkname=pubmed_pubmed&from...
It also doesn't make its way into mainstream practice among GPs and psychiatrists. As an example, which mainstream practitioner would ever prescribe or recommend curcurmin with piperine for any condition, aside from alternative medicine practitioners? Which psychiatrist would recommend EPA fish oil for depression? I could go on. The research that does exist is largely ignored.
Also, the many dead ends thing is true in general for pharma, but at some point there are too many dead ends for it to be profitable even given their bankroll. This is happening a lot lately with neuro-related drug development. In the last 10 years I know Amgen, Pfizer, Novartis, Eli Lilly have all had shut downs/lay offs in their neuroscience research divisions.