Spaces:
Runtime error
Runtime error
import gradio as gr | |
def search(query, selected_strategies): | |
# Add your search logic here | |
results = ["Result 1", "Result 2", "Result 3"] | |
return "\n".join(results) | |
demo = gr.Interface(fn=search, inputs=["text", "checkbox"], outputs="text") | |
with gr.Blocks() as demo: | |
with gr.Row(): | |
input_text = gr.Textbox("text", label="Enter your search query:") | |
default_options = gr.Radio("text", label="Default Options", choices=["Option 1", "Option 2", "Option 3"]) | |
with gr.Row(): | |
with gr.Column(): | |
strategy_1 = gr.Checkbox("text", label="Strategy 1", choices=["ChatGPT", "LLaMA", "Vicuna", "Alpaca", "Flan-T"]) | |
with gr.Column(): | |
strategy_2 = gr.Checkbox("text", label="Strategy 2", choices=["ChatGPT", "LLaMA", "Vicuna", "Alpaca", "Flan-T5"]) | |
with gr.Column(): | |
strategy_3 = gr.Checkbox("text", label="Strategy 3", choices=["ChatGPT", "LLaMA", "Vicuna", "Alpaca", "Flan-T5"]) | |
demo.launch() | |