Spaces:
Sleeping
Sleeping
Try fix syntax error
Browse files
app.py
CHANGED
|
@@ -44,7 +44,7 @@ state = State()
|
|
| 44 |
def update_values(context, question):
|
| 45 |
state.context = context
|
| 46 |
state.question = question
|
| 47 |
-
|
| 48 |
|
| 49 |
with gr.Blocks() as iface:
|
| 50 |
# Create the components with the state values
|
|
@@ -64,7 +64,8 @@ with gr.Blocks() as iface:
|
|
| 64 |
update_btn = gr.Button("Update")
|
| 65 |
update_btn.click(
|
| 66 |
fn=update_values,
|
| 67 |
-
inputs=['test1', 'test2']
|
|
|
|
| 68 |
)
|
| 69 |
|
| 70 |
# Add API endpoint for updating values
|
|
|
|
| 44 |
def update_values(context, question):
|
| 45 |
state.context = context
|
| 46 |
state.question = question
|
| 47 |
+
return state.context
|
| 48 |
|
| 49 |
with gr.Blocks() as iface:
|
| 50 |
# Create the components with the state values
|
|
|
|
| 64 |
update_btn = gr.Button("Update")
|
| 65 |
update_btn.click(
|
| 66 |
fn=update_values,
|
| 67 |
+
inputs=['test1', 'test2'],
|
| 68 |
+
outputs=output
|
| 69 |
)
|
| 70 |
|
| 71 |
# Add API endpoint for updating values
|