Spaces:
Runtime error
Runtime error
Commit
·
20764a9
1
Parent(s):
33959c1
Update app.py
Browse files
app.py
CHANGED
|
@@ -14,9 +14,9 @@ def decide(text):
|
|
| 14 |
padded_tokens = pad_sequences(tokenized_text, maxlen= 200)
|
| 15 |
result = model.predict(padded_tokens, verbose=0)
|
| 16 |
if result[:] > 0.6 :
|
| 17 |
-
return f"Positive review with {result : .0%} prediction score"
|
| 18 |
elif result[:] < 0.4:
|
| 19 |
-
return f"Negative review with {result : .0%} prediction score"
|
| 20 |
else:
|
| 21 |
return "Neutral Review"
|
| 22 |
|
|
|
|
| 14 |
padded_tokens = pad_sequences(tokenized_text, maxlen= 200)
|
| 15 |
result = model.predict(padded_tokens, verbose=0)
|
| 16 |
if result[:] > 0.6 :
|
| 17 |
+
return f"Positive review with {result[:] : .0%} prediction score"
|
| 18 |
elif result[:] < 0.4:
|
| 19 |
+
return f"Negative review with {result[:] : .0%} prediction score"
|
| 20 |
else:
|
| 21 |
return "Neutral Review"
|
| 22 |
|