This commit is contained in:
aaron 2025-05-09 16:23:47 +08:00
parent 7f3c51bc19
commit 418d5e3001
2 changed files with 20 additions and 3 deletions

View File

@ -38,7 +38,19 @@ async def get_agents(current_user: Dict[str, Any] = Depends(get_current_user)):
"name": "加密货币交易助手", "name": "加密货币交易助手",
"hello_prompt": "您好,我是加密货币交易助手,为您提供专业的数字货币交易分析和建议", "hello_prompt": "您好,我是加密货币交易助手,为您提供专业的数字货币交易分析和建议",
"description": "帮你分析做加密货币技术分析", "description": "帮你分析做加密货币技术分析",
} },
{
"id": "2",
"name": "美股交易助手",
"hello_prompt": "您好,我是美股交易助手,为您提供专业的股票交易分析和建议",
"description": "帮你分析做美股股票技术分析",
},
# {
# "id": "3",
# "name": "期货交易助手",
# "hello_prompt": "您好,我是期货交易助手,为您提供专业的期货交易分析和建议",
# "description": "帮你分析做期货技术分析",
# }
] ]
@ -47,8 +59,13 @@ async def chat(request: ChatRequest,current_user: Dict[str, Any] = Depends(get_c
""" """
聊天接口 聊天接口
""" """
if request.agent_id == "1":
token = "app-vhJecqbcLukf72g0uxAb9tcz"
elif request.agent_id == "2":
token = "app-FLIYXrCbbQIkwgXx02Y1Mxjg"
else:
raise HTTPException(status_code=400, detail="Invalid agent ID")
token = "app-vhJecqbcLukf72g0uxAb9tcz"
url = "https://mate.aimateplus.com/v1/chat-messages" url = "https://mate.aimateplus.com/v1/chat-messages"
headers = { headers = {
"Authorization": f"Bearer {token}", "Authorization": f"Bearer {token}",

View File

@ -29,7 +29,7 @@ services:
cryptoai-api: cryptoai-api:
build: . build: .
container_name: cryptoai-api container_name: cryptoai-api
image: cryptoai-api:0.0.8 image: cryptoai-api:0.0.9
restart: always restart: always
ports: ports:
- "8000:8000" - "8000:8000"