Spaces:
Sleeping
Sleeping
File size: 264 Bytes
20d97e8 |
1 2 3 4 5 |
def priority_score(text):
urgent_keywords = ["emergency", "urgent", "severe", "immediate", "pain", "critical"]
score = sum(1 for word in text.lower().split() if word in urgent_keywords)
return "High" if score > 1 else "Medium" if score == 1 else "Low"
|