It’s a great question.
We don’t have a good solution at the moment. This should ideally be documented, but in general is not. The only way to tell, looking at the data, which contexts to join, is to try a join (on
root_id = event_id and root_tstamp = collector_tstamp and if the join is successful then great, if not, then there isn’t the context for that event.
Going forwards we’d like us to add a field to the central
events table with an array of the different contexts attached. (So you wouldn’t have to do the join.) The other piece of metadata that we’d like to attach to the data is the part of speech that each context occupies: so if one context describes the ‘subject’ of the event (i.e. the user that performed the action) then that would be stored in the data.