Make use of --cache by running neuron gen as background process
Per the neuron documentation, we can likely see significant performance improvements with large zettelkastens if we run neuron gen as a background/daemon process and use --cached on query commands.
We can optionally run neuron's web UI as a configurable option, though I am against having it run the web server by default.
From testing this out a bit, the biggest offender is func! s:refresh_backlink_cache_for_zettel(id), and using --cached there sees enormous performance gains.
Yeah, that's pretty much what I expected. Keep in mind, it could quickly become out of date without the mentioned change of having neuron gen in the background.
I'm not familiar with the code base and I'm not fluent in VimL but there seems to be a bug where once you create a new zettel (via gzn), refresh_backlink_cache_for_zettel gets called on each writes.
I suspect it's because g:_neuron_must_refresh_on_write is never set back to 0.
Side note, the performance cost incurred just to be able to show the number of backlinks to a given zettel seems unreasonable.
edit: forgot to add that using --cached should be the default behavior in my opinion until the performance issue can be solved.