wissemkarous commited on
Commit
06badbc
·
verified ·
1 Parent(s): 3330503
Files changed (1) hide show
  1. app.py +3 -6
app.py CHANGED
@@ -1,12 +1,9 @@
1
- import gradio as gr
2
  # Use a pipeline as a high-level helper
3
- from transformers import pipeline
4
-
5
- # pipe = pipeline("text-classification", model="UholoDala/sentence_sentiments_analysis_distilbert")
6
  # we are going to use gradio here
7
 
8
- pipe = pipeline("sentiment-analysis")
9
-
10
  def my_function(text):
11
  out = pipe(text)
12
  out = out[0]["label"] # cleaning the output
 
 
1
  # Use a pipeline as a high-level helper
2
+ from transformers import pipeline, Conversation
3
+ import gradio as gr
4
+ pipe = pipeline("text-classification", model="UholoDala/sentence_sentiments_analysis_distilbert")
5
  # we are going to use gradio here
6
 
 
 
7
  def my_function(text):
8
  out = pipe(text)
9
  out = out[0]["label"] # cleaning the output