m-newhauser commited on
Commit
70ab481
1 Parent(s): 19eb52f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -7
app.py CHANGED
@@ -1,11 +1,14 @@
1
  import gradio as gr
2
 
3
- gr.Interface.load("huggingface/EleutherAI/gpt-j-6B",
4
- inputs=gr.inputs.Textbox(lines=5, label="Input Text") # customizes the input component
5
- ).launch()
 
6
 
7
- def greet(name):
8
- return "Hello " + name + "!!"
 
 
 
9
 
10
- iface = gr.Interface(fn=greet, inputs="text", outputs="text")
11
- iface.launch()
 
1
  import gradio as gr
2
 
3
+ description = "Political tweet classifier"
4
+ title = "Determine whether a tweet skews Republican or Democratic"
5
+ examples = [["Team Biden would rather fund the Ayatollah's Death to America regime than allow Americans to produce energy for our own domestic consumption."],
6
+ ["This pandemic has shown us clearly the vulgarity of our healthcare system. Highest costs in the world, yet not enough nurses or doctors. Many millions uninsured, while insurance company profits soar. The struggle continues. Healthcare is a human right. Medicare for all."]]
7
 
8
+ interface = gr.Interface.load("huggingface/m-newhauser/distilbert-political-tweets",
9
+ description=description,
10
+ examples=examples,
11
+ allow_flagging=False
12
+ )
13
 
14
+ interface.launch()