Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,10 +1,6 @@
|
|
| 1 |
-
import gradio as gr
|
| 2 |
from transformers import pipeline
|
| 3 |
|
| 4 |
-
|
| 5 |
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
iface = gr.Interface(fn=predict, inputs="text", outputs="json")
|
| 10 |
-
iface.launch()
|
|
|
|
|
|
|
| 1 |
from transformers import pipeline
|
| 2 |
|
| 3 |
+
sentiment_pipeline = pipeline("text-classification", model="hasanmustafa0503/SentimentModel")
|
| 4 |
|
| 5 |
+
result = sentiment_pipeline("I love this!")
|
| 6 |
+
print(result)
|
|
|
|
|
|
|
|
|