gr.Blocks
Browse files
app.py
CHANGED
@@ -3,6 +3,15 @@ import gradio as gr
|
|
3 |
def greet(name):
|
4 |
return "ChatDulun is ChatGPT induced disruption to Higher Education \n" + name + "!!"
|
5 |
|
6 |
-
iface = gr.Interface(fn=greet, inputs="text", outputs="text", title='ChatDulun = Higher Education Disrupted',
|
7 |
-
|
8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
def greet(name):
|
4 |
return "ChatDulun is ChatGPT induced disruption to Higher Education \n" + name + "!!"
|
5 |
|
6 |
+
# iface = gr.Interface(fn=greet, inputs="text", outputs="text", title='ChatDulun = Higher Education Disrupted',
|
7 |
+
# css=""" body { background-color: red } .input_text input { background-color: green } """)
|
8 |
+
|
9 |
+
with gr.Blocks() as demo:
|
10 |
+
gr.HTML("""<h1 align="center">ChatGPT is Here to Disrupt</h1>""")
|
11 |
+
name = gr.Textbox(label='Guest Name')
|
12 |
+
output = gr.Textbox(label='Greetings !')
|
13 |
+
greet_btn = gr.Button("Greet")
|
14 |
+
greet_btn.click(fn=greet, inputs=name, outputs=output)
|
15 |
+
|
16 |
+
demo.title= 'ChatDulun = Higher Education Disrupted'
|
17 |
+
demo.launch()
|