CognitiveScience commited on
Commit
13c256e
1 Parent(s): f198d13

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -3
app.py CHANGED
@@ -83,9 +83,15 @@ with gr.Blocks(api_name=["/ccogsphere"]) as demo:
83
  review = gr.Textbox(label="b") #, placeholder="What is your name?") #gr.Radio(label="How satisfied are you with using gradio?", choices=[1, 2, 3, 4, 5])
84
  comments = gr.Textbox(label="c") #, lines=10, placeholder="Do you have any feedback on gradio?")
85
  submit = gr.Button(value=".")
86
-
87
- submit.click(ccogsphere, [name, review, comments], [data, count])
88
- #demo.load(load_data, None, [data, count])
 
 
 
 
 
 
89
 
90
  def backup_db():
91
  shutil.copyfile(DB_FILE, "./data/reviews.db")
 
83
  review = gr.Textbox(label="b") #, placeholder="What is your name?") #gr.Radio(label="How satisfied are you with using gradio?", choices=[1, 2, 3, 4, 5])
84
  comments = gr.Textbox(label="c") #, lines=10, placeholder="Do you have any feedback on gradio?")
85
  submit = gr.Button(value=".")
86
+
87
+
88
+ submit.click(ccogsphere, [name, review, comments], [data, count])
89
+ demo.load(load_data, None, [data, count])
90
+ @name.change(inputs=name, outputs=output)
91
+ def secwork(name):
92
+ if name="abc"
93
+ demo.load(load_data, None, [data, count])
94
+ return "Hello " + name + "!"
95
 
96
  def backup_db():
97
  shutil.copyfile(DB_FILE, "./data/reviews.db")