跳到主要内容

seedream 系列

seedream 系列统一入口说明

  1. 本页说明平台 POST /v1/images/generations 在 seedream 系列上的实际行为。
  2. 重点是统一入口里的参数行为与规则,不只是字段表面含义。

基础信息

项目说明
统一入口POST /v1/images/generations
鉴权方式Authorization: Bearer YOUR_API_KEY
适用模型doubao-seedream-4.0doubao-seedream-4.5bytedance-seedream-5.0

建议先在 shell 里准备两个变量:

BASE_URL="https://api-platform.ope.ai"
API_KEY="YOUR_API_KEY"

价格信息请查看:模型价格

1. 统一入口字段行为

统一入口字段平台处理说明
model归一化会做 seedream 模型名归一化(见下表)
prompt直接处理作为提示词传入
size直接处理未传时按模型补默认值
response_format约束校验仅接受 b64_jsonurl
image直接处理支持图生图/多图融合
stream默认值默认 false
watermark默认值默认 false
sequential_image_generation条件生效仅 seedream 模型生效,支持 disabledauto
n条件改写仅在 seedream 且 n > 1 且未显式传 sequential_image_generation 时,自动改写为 auto + max_images=n

当前统一入口不生效字段:qualitystyleuseroutput_formatoutput_compressionbackgroundmoderation

2. 模型 ID 归一化(平台内部)

请求 model归一化后 model
doubao-seedream-4.5 / doubao-seedream-4-5-251128seedream-4-5-251128
doubao-seedream-4.0 / doubao-seedream-4-0-250828seedream-4-0-250828
bytedance-seedream-5.0bytedance-seedream-5.0

size 默认值规则:

  • doubao-seedream-3-0-t2i-250415 / seedream-3-0-t2i-250415:默认 1024x1024
  • 对其他 seedream:默认 2K

3. Size 可用值(seedream 原生规格)

平台对 size 做透传。你可以传 2K / 3K / 4K,也可以直接传具体分辨率(推荐直接传分辨率)。
参考:火山引擎官方文档 图像生成

档位比例分辨率(size
2K1:12048x2048
2K4:32304x1728
2K3:41728x2304
2K16:92848x1600
2K9:161600x2848
2K3:22496x1664
2K2:31664x2496
2K21:93136x1344
3K1:13072x3072
3K4:33456x2592
3K3:42592x3456
3K16:94096x2304
3K9:162304x4096
3K2:32496x3744
3K3:23744x2496
3K21:94704x2016
4K1:14096x4096
4K3:43520x4704
4K4:34704x3520
4K16:95504x3040
4K9:163040x5504
4K2:33328x4992
4K3:24992x3328
4K21:96240x2656

4. n 参数语义(重点)

  • n 默认值是 1
  • seedream 系列中,n 不是“强制生成 n 张”。
  • 实际逻辑是:在组图模式下,n 仅作为 max_images 上限,最终出图张数由模型根据提示词自动决定。
  • 官方上限建议为 [1, 15];建议按该范围传参。

网关自动改写示例(当 n > 1 且你未显式传 sequential_image_generation):

{
"sequential_image_generation": "auto",
"sequential_image_generation_options": {
"max_images": 8
}
}

5. 创建请求示例

curl --request POST "$BASE_URL/v1/images/generations" \
--header "Authorization: Bearer $API_KEY" \
--header "Content-Type: application/json" \
--data '{
"model": "bytedance-seedream-5.0",
"prompt": "生成一组同一角色在不同机位下的电影感海报,画面风格统一。",
"size": "4096x2304",
"n": 8,
"response_format": "url"
}'