zerobase-io / smart-tracing-api

Backend/DB/API repository for the Zerobase platform
Apache License 2.0
6 stars 9 forks source link

Implement an initial basic "risk assessment measure" #76

Open brianok77 opened 4 years ago

brianok77 commented 4 years ago

NOTE: We are waiting for some expert advice on the values below here, so some placeholders or parameters may change. Also some walkthrough examples will likely be provided.

This risk assessment measure will do the following:

  1. Find all "contacts" the user had within N (N=3?) hops. For each scan by the device with the last X days (X TBD), all devices that scanned the same site between 4 and 0 hours prior are considered a contact. Repeat this same procedure for each contact up to N hops.
  2. For each "contact", inspect their test results to see if any have positive test results within -Y(1) and +Y(2) days of the scan (Y(1) and Y(2) TBD)
  3. For each positive contact, add a value of W to their risk score, where W is dependent upon the number of hops (N) from the device being evaluated.

This story should be reviewed by the medical/epidemiology experts for accuracy. Again, some detailed walkthrough examples will be created to ensure everyone understands this and to provide some test cases for development.