updated with real triage methodology
This commit is contained in:
Binary file not shown.
@@ -181,18 +181,18 @@ class WristbandSimulator:
|
||||
return int(hr), int(spo2), temp, self.activity_level
|
||||
|
||||
def _determine_tier(self, hr: int, spo2: int, temp: float) -> tuple:
|
||||
"""Determine alert tier based on vitals"""
|
||||
"""Determine flags based on vitals - tier determined by backend"""
|
||||
flags = 0
|
||||
|
||||
# Battery warning
|
||||
if self.battery < 15:
|
||||
flags |= VitalFlags.LOW_BATT
|
||||
|
||||
# Check for critical vitals (EMERGENCY)
|
||||
# Set EMERGENCY flag if critical vitals
|
||||
if hr > 140 or hr < 45 or spo2 < 88 or temp > 39.5 or temp < 35.0:
|
||||
flags |= VitalFlags.EMERGENCY
|
||||
tier = "EMERGENCY"
|
||||
# Check for concerning vitals (ALERT)
|
||||
# Set ALERT flag if concerning vitals
|
||||
elif hr > 110 or hr < 50 or spo2 < 92 or temp > 38.3 or temp < 35.5:
|
||||
flags |= VitalFlags.ALERT
|
||||
tier = "ALERT"
|
||||
|
||||
Reference in New Issue
Block a user