Closed HeinzSchmidt closed 7 years ago
my first approach would be saving all concepts as json, its simple and stuctures without introducing dependencies, but this is not my area so feedback is welcome
For the data structure, if we start with JSON for the sake of illustration:
'{ { "name": "Cow", "parents": [ { "gen1" : "herbivore", "gen2" : "animal" } ], "data_dict" : "Cow is the nickname for cattle, and the name of adult female cattle." }, { "name": "Herbivore", "parents": [ { "gen1" : "animal", "gen2" : "life" }, "data_dict" : "A herbivore is an animal anatomically and physiologically adapted to eating plant material, for example foliage, for the main component of its diet. As a result of their plant diet, herbivorous animals typically have mouthparts adapted to rasping or grinding. Horses and other herbivores have wide flat teeth that are adapted to grinding grass, tree bark, and other tough plant material." ] } }'
i think we could also go with data BackEnds, so the user can config how he wants data stored, this backend would also be usefull for other skills that save data to use
this also brings the question, where will data be stored? should we create a database folder or inside LILACS skill folder is ok?
Yes, it would have to be in a location where it won't be messed with. Inside the skills folder in a ".db" subfolder should work?
In future, the config file will have the storage location of the LILACS datastore / db file and it can point to:
The possibilities are endless
a storage service was created, currently defaults to json, opening an issue for each new backend
https://github.com/ElliotTheRobot/LILACS-mycroft-core/tree/dev/mycroft/storage
What are we using for the relational concept data storage? Considerations:
I'm thinking sqllite3 ? Any other ideas?