Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -4,9 +4,9 @@ from sentiment import vectr, clf
|
|
4 |
def predict(text):
|
5 |
senti = clf.predict(vectr.transform([text]))
|
6 |
if (int(senti)):
|
7 |
-
text_sent = "Positive Sentiment
|
8 |
else:
|
9 |
-
text_sent = "Negative Sentiment
|
10 |
return text_sent
|
11 |
|
12 |
demo = gr.Interface(fn=predict, inputs="text", outputs="text")
|
|
|
4 |
def predict(text):
|
5 |
senti = clf.predict(vectr.transform([text]))
|
6 |
if (int(senti)):
|
7 |
+
text_sent = "Positive Sentiment Detected😊"
|
8 |
else:
|
9 |
+
text_sent = "Negative Sentiment Detected😟"
|
10 |
return text_sent
|
11 |
|
12 |
demo = gr.Interface(fn=predict, inputs="text", outputs="text")
|