I'm looking for a module - if it exists - that is an API for creating a traditional tree data structure (like a decision tree) and saving and loading it from a data source (like a MongoDB document). Ideally this API would allow splicing trees at any node and then resaving them to the DB and also retrieval of any node via an ID.
I've found the following:
None of these seem to be a full solution for my decision-tree needs. And it is quite possible that I'm approaching this the wrong way.
Suggestions?
EDIT:
Found tree-model and it seems promising, but still no API for interaction with a DB. Perhaps I will write one.
After looking into this and not finding a substantial solution for what I wanted, I wrote my own: