donadelicc commited on
Commit
7b31d6c
1 Parent(s): 0397641
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -19,13 +19,13 @@ def predict(text):
19
  confidence= f"{confidence_score:.2%}"
20
 
21
  if str(prediction[0]) == "1":
22
- label = "negative"
23
  elif str(prediction[0]) == "2":
24
- label = "positive"
25
  else:
26
  label = "dunno"
27
 
28
- output = f"Prediction: {label} and Confidence: {confidence}"
29
 
30
  print(prediction)
31
  return output, confidence
 
19
  confidence= f"{confidence_score:.2%}"
20
 
21
  if str(prediction[0]) == "1":
22
+ label = "NEGATIVE"
23
  elif str(prediction[0]) == "2":
24
+ label = "POSITIVE"
25
  else:
26
  label = "dunno"
27
 
28
+ output = f"Prediction: {label} \n Confidence: {confidence}"
29
 
30
  print(prediction)
31
  return output, confidence