A user represents a user’s account information. It contains their unique identifiers and is required for logging in.
A profile is how we link questionaire responses to a user.
A membership represents how a user is connected to groupings.
There should be a membership entry referencing every grouping a user belongs to.
Each membership can be marked as active with the membership.is_active key. This allows for a history of memberships to be persisted, and allows the joining and leaving of groupings. Leaving a grouping is a matter of marking the membership.is_active as false.
If the membership.can_edit key is true, the member user is allowed to edit the grouping details.
A grouping is a representation of membership between two profiles.
Each grouping consists of atleast two profiles.
Some common groupings include: companies and matches
A message is the record of a chat message for each grouping's chat.
A response represents a questionaire answer that is linked to a profile and ultimately a user for scoring and matching. Each response references a response_key.
A response_key represents how each response is categorized as well as the actual question asked on the questionaire.
We group responses into broader ctegories to aid scoring.
The response.response_key_category is the category and the response.response_key_prompt stores the question itself.