From fd4cd62636b78c2e83df1fc27d55df5b5154cc8b Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Wed, 5 Jan 2022 12:54:35 +0100 Subject: [PATCH] Add README for internal data representation --- README.md | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 31a8a2c..6f2fafb 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # habit-migrate -Can take an export of nomie habits in json format and convert it to be importable in Loop Habit Tracker. +Can take an export of [nomie](https://nomie.app/) habits in json format and convert it to be importable in [Loop Habit Tracker](https://loophabits.org/). Confirmed working for nomie version 5.6.4 and Loop Habit Tracker version 2.0.2 and 2.0.3. Presumably works for other nomie 5.x versions and other Loop 2.x versions as well, @@ -32,3 +32,22 @@ In the future there might be an easier road to using this package but that's the The package can also be used as a library to load nomie data or move data into Loop Habit Tracker. +## Internal representation + +Internally, the data gets represented within three concepts: +Events, Activities and Trackers. + +Events are simple entries or logs of, basically, anything and represent *qualitative* data. +At their most basic, they only describe 'something' at a certain point in time. +For that, they have to contain a time and they may contain prose text (i.e. an arbitrary text string). +Additionally, an event can contain a list of one or more activities. + +Activities are the changes to whatever is tracked *quantitatively*. +They always belong to an event and thus the moment in time the event took place. +They might even be the only interesting thing that took place in the event, +but not necessarily. +Lastly, they contain a single tracker which they belong to. + +Trackers are the meta-data of whatever is being tracked quantitatively through activities. +They define a name, label, scores, descriptions, reminders and so on. +All data being imported is transformed into this model and output from it again.