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()
|