新增客服重定向接口

This commit is contained in:
2025-11-28 10:12:41 +08:00
parent eb361fe77f
commit 9200df7842
2 changed files with 96 additions and 0 deletions
+4
View File
@@ -16,6 +16,7 @@ load_dotenv()
import sys
from rag2_0.intent_recognition import AsyncIntentRecognizer
from rag2_0.api.kefu_redirect_url import router as kefu_router
# 确保日志目录存在
os.makedirs('data/logs', exist_ok=True)
@@ -84,6 +85,9 @@ app.add_middleware(
allow_headers=["*"],
)
# 注册外部路由
app.include_router(kefu_router)
# 全局变量存储AsyncIntentRecognizer实例
_instance = None