good version for web

This commit is contained in:
2026-02-18 09:36:18 +08:00
parent 62ea5d36a5
commit 72ab0c0b56
42 changed files with 1305 additions and 1515 deletions

View File

@@ -237,6 +237,21 @@ async def delete_version(
# 算法调用相关路由
@router.post("/call/public", response_model=AlgorithmCallResult)
async def call_algorithm_public(
call: AlgorithmCallCreate,
db: Session = Depends(get_db)
):
"""公开调用算法(不需要认证,用于演示页面)"""
# 使用匿名用户ID进行调用
anonymous_user_id = "anonymous"
# 执行算法
result = AlgorithmCallService.execute_algorithm(db, anonymous_user_id, call)
return result
@router.post("/call", response_model=AlgorithmCallResult)
async def call_algorithm(
call: AlgorithmCallCreate,