import gradio as gr from src.rag import chat def response(message, history): history = history or [] response_text = chat(message) history.append({"role": "user", "content": message}) history.append({"role": "assistant", "content": response_text}) return history demo = gr.ChatInterface(fn=response, type="messages", examples=["hello", "hola", "merhaba"], title="Echo Bot") demo.launch(share=True)