import gradio as gr from ai_model import query_ai_model # Import AI model query function # Function to handle chatbot conversation def gradio_chatbot(text, history): history.append((text, None)) response = asyncio.run(query_ai_model(text)) history[-1] = (text, response) return history # Gradio interface def create_gradio_interface(): chatbot = gr.Chatbot() textbox = gr.Textbox(placeholder="Ask a question and press Enter", show_label=False) # Set up the Gradio interface layout with gr.Blocks() as demo: gr.HTML("