cooelf commited on
Commit
6ced780
1 Parent(s): 3e7a53c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +13 -3
app.py CHANGED
@@ -46,10 +46,20 @@ with gr.Blocks(css="""
46
  fn=inference, inputs=inputs, outputs=outputs, show_progress=True
47
  )
48
  title = "Tutorial: BERT-based Text Classificatioin",
 
 
 
 
 
 
 
 
 
49
  examples = [
50
  ["My last two weather pics from the storm on August 2nd. People packed up real fast after the temp dropped and winds picked up.", 1],
51
  ["Lying Clinton sinking! Donald Trump singing: Let's Make America Great Again!", 0],
52
  ],
53
-
54
- demo.queue()
55
- demo.launch()
 
 
46
  fn=inference, inputs=inputs, outputs=outputs, show_progress=True
47
  )
48
  title = "Tutorial: BERT-based Text Classificatioin",
49
+
50
+
51
+ demo.queue()
52
+ demo.launch()
53
+
54
+ demo = gr.Interface(
55
+ fn=inference,
56
+ inputs=gr.Textbox(label="Input Text", scale=2, container=False),
57
+ outputs=gr.outputs.Textbox(label="Output Label"),
58
  examples = [
59
  ["My last two weather pics from the storm on August 2nd. People packed up real fast after the temp dropped and winds picked up.", 1],
60
  ["Lying Clinton sinking! Donald Trump singing: Let's Make America Great Again!", 0],
61
  ],
62
+ title="Tutorial: BERT-based Text Classificatioin",
63
+ )
64
+
65
+ demo.launch(debug=True)