Update app.py
Browse files
app.py
CHANGED
@@ -1312,18 +1312,6 @@ def chat_or_recommend(req: ChatOrRecommendRequest):
|
|
1312 |
def run_fastapi():
|
1313 |
uvicorn.run(app, host="0.0.0.0", port=7860)
|
1314 |
|
1315 |
-
def chatbot_interface(user_input, mode):
|
1316 |
-
return chat_response(user_input, mode)
|
1317 |
-
|
1318 |
-
iface = gr.Interface(
|
1319 |
-
fn=chatbot_interface,
|
1320 |
-
inputs=["text", gr.Radio(["emotion", "rational"], label="Mode")],
|
1321 |
-
outputs="text",
|
1322 |
-
title="Chatbot Interface",
|
1323 |
-
description="FastAPI ๊ธฐ๋ฐ ์ฑ๋ด + ์ถ์ฒ ์์คํ
",
|
1324 |
-
flagging_mode="off" # flagging ๋นํ์ฑํ
|
1325 |
-
)
|
1326 |
-
|
1327 |
|
1328 |
if __name__ == "__main__":
|
1329 |
Thread(target=run_fastapi).start()
|
|
|
1312 |
def run_fastapi():
|
1313 |
uvicorn.run(app, host="0.0.0.0", port=7860)
|
1314 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1315 |
|
1316 |
if __name__ == "__main__":
|
1317 |
Thread(target=run_fastapi).start()
|