音频文件上传 | AI创作模块兼容音频

This commit is contained in:
2026-07-03 11:44:32 +08:00
parent 899732aa54
commit 28b1d24173
14 changed files with 209 additions and 8 deletions
+4
View File
@@ -135,6 +135,10 @@ async def submit_video_task(
resolved = _resolve_url(ref_url)
role = ref_role if ref_role else "reference_video"
content.append({"type": "video_url", "video_url": {"url": resolved}, "role": role})
elif ref_type == "audio" and ref_url:
resolved = _resolve_url(ref_url)
role = ref_role if ref_role else "reference_audio"
content.append({"type": "audio_url", "audio_url": {"url": resolved}, "role": role})
except (json.JSONDecodeError, TypeError):
pass