Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -113,13 +113,11 @@ def chat_interface(messages):
|
|
113 |
return chat_history
|
114 |
|
115 |
# Create Gradio interface
|
116 |
-
|
117 |
-
chat_interface,
|
118 |
-
type="messages"
|
119 |
-
)
|
120 |
|
121 |
# Mount both FastAPI and Gradio
|
122 |
-
app = gr.mount_gradio_app(app,
|
123 |
|
124 |
# For running with uvicorn directly
|
125 |
if __name__ == "__main__":
|
|
|
113 |
return chat_history
|
114 |
|
115 |
# Create Gradio interface
|
116 |
+
def gradio_app():
|
117 |
+
return gr.Chatbot(chat_interface, type="messages", value=[])
|
|
|
|
|
118 |
|
119 |
# Mount both FastAPI and Gradio
|
120 |
+
app = gr.mount_gradio_app(app, gradio_app(), path="/")
|
121 |
|
122 |
# For running with uvicorn directly
|
123 |
if __name__ == "__main__":
|