quocviethere commited on
Commit
87375a2
1 Parent(s): dcf4bbc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -5
app.py CHANGED
@@ -9,12 +9,13 @@ def predict_sentiment(text):
9
  return "Positive Review", model_output[1]
10
 
11
  iface = gr.Interface(
12
- fn=predict_sentiment,
13
- inputs=gr.inputs.Textbox(lines=2, placeholder="Type your review here"),
14
- outputs=[
15
- gr.outputs.Label(num_top_classes=2, label="Sentiment Analysis")
16
- ]
17
  )
18
 
 
 
 
19
  iface.launch()
20
 
 
9
  return "Positive Review", model_output[1]
10
 
11
  iface = gr.Interface(
12
+ fn=predict_sentiment,
13
+ inputs=gr.Textbox(lines=2, placeholder="Type your review here"), # define the text input
14
+ outputs=gr.Label(num_top_classes=2) # define the output as a label
 
 
15
  )
16
 
17
+ # Launch the interface
18
+ iface.launch()
19
+
20
  iface.launch()
21