SamanthaStorm commited on
Commit
cdc45c3
·
verified ·
1 Parent(s): f9982b7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -333,7 +333,7 @@ def compute_abuse_score(matched_scores, sentiment):
333
 
334
  return min(adjusted_score, 100)
335
  def get_emotion_profile(text):
336
- emotions = emotion_pipeline(text)
337
  if isinstance(emotions, list) and isinstance(emotions[0], list):
338
  emotions = emotions[0]
339
  return {e['label'].lower(): round(e['score'], 3) for e in emotions}
 
333
 
334
  return min(adjusted_score, 100)
335
  def get_emotion_profile(text):
336
+ emotions = emotion_pipeline(text)
337
  if isinstance(emotions, list) and isinstance(emotions[0], list):
338
  emotions = emotions[0]
339
  return {e['label'].lower(): round(e['score'], 3) for e in emotions}