Spaces:
Sleeping
Sleeping
aaaaa
Browse files55 unmodified lines5657585960616256 unmodified lines11912012112112212312412512612712812913013113213355 unmodified linesdef cancel_inference(): global stop_inference stop_inference = True return gr.update(label="Inference cancelled.")
# Custom CSS for a fancy lookcustom_css = """56 unmodified lines label="Top-p (nucleus sampling)", ), gr.Checkbox(label="Use Local Model", value=False), gr.Button("Cancel Inference", variant="danger", on_click=cancel_inference), gr.Button("Cancel Inference"), ], css=custom_css, title="🌟 Fancy AI Chatbot 🌟", description="Interact with the AI chatbot using customizable settings below.")
cancel_button = demo.add_button("Cancel Inference", variant="danger", elem_id="cancel_button")cancel_button.click(cancel_inference, None, None)
if __name__ == "__main__": demo.launch()app.py+5-1