AI 模型值
介绍 Aether API 中可用的 AI 模型及各模型特性。
AiModelType 枚举
图像生成请求可用的 AI 模型列表。
| 模型值 | 说明 |
|---|---|
GPT Image 1.5 | OpenAI GPT Image 1.5 模型 |
Grok Imagine | xAI Grok Imagine 模型 |
Grok Imagine Pro | xAI Grok Imagine Pro 模型 |
Nano Banana | Nano Banana 模型 |
Nano Banana 2 | Nano Banana 2 模型 |
Nano Banana Pro | Nano Banana Pro 模型 |
参考图像限制
每个模型对 ref_images 参数允许的最大图像数量不同。
| 模型 | 最大参考图像数 |
|---|---|
GPT Image 1.5 | 10个 |
Grok Imagine | 5个 |
Grok Imagine Pro | 1个 |
Nano Banana | 10个 |
Nano Banana 2 | 10个 |
Nano Banana Pro | 10个 |
请求示例
基本生成
curl -X POST "https://api.aetherforgeai.com/public/v1/generate" \
-H "Authorization: Bearer your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"prompt": "A beautiful sunset over mountains",
"ai_model": "GPT Image 1.5"
}'
包含参考图像 (Grok Imagine Pro)
curl -X POST "https://api.aetherforgeai.com/public/v1/generate" \
-H "Authorization: Bearer your_api_key_here" \
-F "prompt=A cat in the style of the reference image" \
-F "ai_model=Grok Imagine Pro" \
-F "[email protected]"
包含参考图像 (GPT Image 1.5 - 最多 10 个)
curl -X POST "https://api.aetherforgeai.com/public/v1/generate" \
-H "Authorization: Bearer your_api_key_here" \
-F "prompt=A landscape combining these styles" \
-F "ai_model=GPT Image 1.5" \
-F "[email protected]" \
-F "[email protected]" \
-F "[email protected]"
错误响应
400 Bad Request - 参考图像超出限制
当超过模型的最大参考图像数量时返回。
Grok Imagine Pro 示例:
{
"detail": "The Grok Imagine Pro model supports up to 1 ref_images."
}
一般限制示例:
{
"detail": "ref_images supports up to 10 images only"
}
模型选择指南
| 使用场景 | 推荐模型 |
|---|---|
| 高质量一般图像生成 | GPT Image 1.5 |
| 需要风格参考时 | Grok Imagine (最多 5 个) |
| 单张参考图像获得高质量结果 | Grok Imagine Pro |
| 需要多张参考图像时 | Nano Banana 系列 (最多 10 个) |
相关文档
- POST /public/v1/generate/image - 图像生成端点
- 异步作业生命周期 - 作业处理流程