Spaces:
Running
Running
Nattapong Tapachoom
commited on
Commit
·
da68305
1
Parent(s):
66d994e
Add model dropdown change event to trigger analysis in Gradio app
Browse files
app.py
CHANGED
@@ -208,6 +208,10 @@ with gr.Blocks(
|
|
208 |
return analyze_text(text, model_name)
|
209 |
analyze_btn.click(analyze_wrapper, inputs=[text_input, model_dropdown], outputs=output_box)
|
210 |
text_input.submit(analyze_wrapper, inputs=[text_input, model_dropdown], outputs=output_box)
|
|
|
211 |
model_dropdown.change(analyze_wrapper, inputs=[text_input, model_dropdown], outputs=output_box)
|
212 |
|
|
|
|
|
|
|
213 |
|
|
|
208 |
return analyze_text(text, model_name)
|
209 |
analyze_btn.click(analyze_wrapper, inputs=[text_input, model_dropdown], outputs=output_box)
|
210 |
text_input.submit(analyze_wrapper, inputs=[text_input, model_dropdown], outputs=output_box)
|
211 |
+
|
212 |
model_dropdown.change(analyze_wrapper, inputs=[text_input, model_dropdown], outputs=output_box)
|
213 |
|
214 |
+
# เรียกใช้งาน Gradio app
|
215 |
+
demo.queue().launch()
|
216 |
+
|
217 |
|