1
This commit is contained in:
@@ -121,6 +121,9 @@ async def list_engines(
|
||||
"该接口用于 Chat 风格的图片/视频生成,不再绑定 project_id。"
|
||||
"创建成功后会写入 chat_generation_tasks 表,并投递 Celery 异步任务。"
|
||||
"支持 image 图片生成和 video 视频生成。"
|
||||
"media_references 支持 image/video/audio;source 可为 upload_resource=历史上传素材、"
|
||||
"private_portrait_asset=私域真人/虚拟素材、空=本次普通上传素材。"
|
||||
"视频/音频参考素材必须携带 duration,并按 AI 创作原逻辑校验单段 2~15 秒、总时长不超过 15 秒。"
|
||||
"建议前端传入 idempotency_key,用于防止按钮连点、网络重试导致重复创建任务和重复扣费。"
|
||||
),
|
||||
responses={
|
||||
@@ -141,7 +144,12 @@ async def list_engines(
|
||||
async def create_task(
|
||||
req: GenerationAITaskCreate = Body(
|
||||
...,
|
||||
description="AI生成任务创建参数。gen_type=image 时使用图片参数;gen_type=video 时使用视频参数",
|
||||
description=(
|
||||
"AI生成任务创建参数。gen_type=image 时使用图片参数;gen_type=video 时使用视频参数。"
|
||||
"枚举:gen_type=image/video;media_references[].type=image/video/audio;"
|
||||
"media_references[].source=upload_resource/private_portrait_asset/空;"
|
||||
"media_references[].role=first_frame/last_frame/reference_image/reference_video/reference_audio。"
|
||||
),
|
||||
),
|
||||
current_user: User = Depends(get_current_user),
|
||||
db: AsyncSession = Depends(get_db),
|
||||
@@ -186,7 +194,8 @@ async def create_task(
|
||||
"分页获取当前登录用户的AI生成任务列表。"
|
||||
"可按生成类型 gen_type 和任务状态 status 过滤。"
|
||||
"该接口返回的是普通任务列表,不按日期分组。"
|
||||
"如果前端需要按生成日期分组展示历史记录,请使用 /generation-ai/history 接口。"
|
||||
"如果前端需要按生成日期分组展示生成历史记录,请使用 /generation-ai/history 接口。"
|
||||
"上传素材历史不是生成历史,请使用 /upload-resources/history。"
|
||||
),
|
||||
responses={
|
||||
200: {
|
||||
|
||||
Reference in New Issue
Block a user