JoannaKOKO commited on
Commit
ff72da5
·
verified ·
1 Parent(s): dac01f4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -4
app.py CHANGED
@@ -181,10 +181,14 @@ def main():
181
 
182
  # Connect the button to the processing function
183
  submit_btn.click(
184
- fn=process_tarot,
185
- inputs=[question, reason_img, result_img, recommendation_img],
186
- outputs=output
187
- )
 
 
 
 
188
 
189
  # Launch the application
190
  demo.launch()
 
181
 
182
  # Connect the button to the processing function
183
  submit_btn.click(
184
+ fn=lambda: "Reading in progress...", # Show progress message
185
+ inputs=None,
186
+ outputs=output
187
+ ).then(
188
+ fn=process_tarot, # Run the tarot reading
189
+ inputs=[question, reason_img, result_img, recommendation_img], # Pass all inputs
190
+ outputs=output # Update the same output with the result
191
+ )
192
 
193
  # Launch the application
194
  demo.launch()