sandboxnu / boba-buddies

Sandbox's virtual water cooler conversation app.
GNU General Public License v3.0
1 stars 0 forks source link

make our json as a database more sophisticated #26

Open VKong6019 opened 2 years ago

VKong6019 commented 2 years ago

from our last meeting, we agreed that we should keep track a couple more statistics in our s3 file to create our own bobabuddies wrapped.

Currently, i believe the json file in s3 only keep tracks of number of pairs overall. So, we now want to add onto this and keep track of each person's

Just so we don't forget, the bobabuddies wrapped we'll create is being sent biweekly, so we want to make sure data is "reset" accordingly. This would probably be used when tracking the number of pairs met in each cycle as well as before each semester to start a clean state.

justineluo commented 2 years ago

thank u supreme leader <3

jia614 commented 2 years ago

ty project mommy

justineluo commented 2 years ago

I have a proposed data structure. Thoughts?


/**

This json represents 
pairsMet - the total number of pairs met during this cycle (a semester)
timesMet - number of times each user met with their buddies during the cycle
longestStreaks - the longest streak of each user meeting their buddy
currentStreaks - current streak of each user meeting their buddy
*/

{
  "pairsMet": 4, 
  "timesMet": 
    {
      "aloe": 2, // in practice, these should be user ids rather than display names (needs to be unique)
      "KEKW Lead" : 1,
      "on jia": 2
    },
  "longestStreaks": {
     "aloe": 20,
     "KEKW Lead" : 10,
     "on jia": 15
  },
  "currentStreaks": {
     "aloe": 3,
     "KEKW Lead" : 1,
     "on jia": 12
  },
}
VKong6019 commented 2 years ago

Yus, that looks good to me