MiniMax Image Generation

MiniMax AI图片生成,支持 image-01 和 image-01-live 模型。 image-01: 画面表现细腻,支持文生图、图生图 image-01-live: 手绘、卡通等画风增强,支持文生图并进行画风设置 需要 MiniMax API Key (Coding Plan)。

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "MiniMax Image Generation" with this command: npx skills add wanycun/minimax-image-generation

MiniMax Image Generation

使用 MiniMax Coding Plan API 调用 image-01、image-01-live 模型生成图片。

环境配置

API Key 获取: https://platform.minimaxi.com/user-center/basic-information/interface-key

export MINIMAX_API_KEY="your-api-key"

支持模型

模型说明支持比例
image-01画面表现细腻,支持文生图、图生图1:1, 16:9, 4:3, 3:2, 2:3, 3:4, 9:16, 21:9
image-01-live手绘、卡通等画风增强1:1, 16:9, 4:3, 3:2, 2:3, 3:4, 9:16

支持比例

  • 1:1 (1024x1024) - 默认
  • 16:9 (1280x720)
  • 4:3 (1152x864)
  • 3:2 (1248x832)
  • 2:3 (832x1248)
  • 3:4 (864x1152)
  • 9:16 (720x1280)
  • 21:9 (1344x576) - 仅 image-01

使用方法

命令行

# 列出可用模型
python3 scripts/minimax_image_create.py --list-models

# 文生图 (image-01)
python3 scripts/minimax_image_create.py \
  --api-key $MINIMAX_API_KEY \
  --model image-01 \
  --prompt "一只可爱的橘猫" \
  --aspect-ratio 16:9

# 文生图 (image-01-live)
python3 scripts/minimax_image_create.py \
  --api-key $MINIMAX_API_KEY \
  --model image-01-live \
  --prompt "一只可爱的橘猫" \
  --style watercolor

# 图生图
python3 scripts/minimax_image_create.py \
  --api-key $MINIMAX_API_KEY \
  --model image-01 \
  --prompt "转换成水彩画风格" \
  --input-image https://example.com/image.jpg

参数说明

参数说明默认值
--api-keyMiniMax API Key环境变量 MINIMAX_API_KEY
--model模型名称 (image-01/image-01-live)image-01
--prompt图像描述 (必填)-
--aspect-ratio宽高比1:1
--width自定义宽度 (仅 image-01)-
--height自定义高度 (仅 image-01)-
--n生成数量 [1-9]1
--seed随机种子随机
--prompt-optimizer开启 prompt 自动优化false
--aigc-watermark添加水印false
--response-format返回格式 (url/base64)url
--input-image输入图片 (图生图)-
--style画风 (仅 image-01-live)-
--output-jsonJSON 格式输出-

image-01-live 画风选项

⚠️ 注意: style 参数当前可能不稳定,建议先用默认设置生成。

  • realistic - 写实
  • animation - 动画
  • comic - 漫画
  • watercolor - 水彩
  • oil_painting - 油画
  • sketch - 素描
  • cartoon - 卡通
  • hand_drawn - 手绘

API 参考

端点: POST https://api.minimaxi.com/v1/image_generation

请求头:

Authorization: Bearer <API_KEY>
Content-Type: application/json

请求体:

{
  "model": "image-01",
  "prompt": "图像描述",
  "aspect_ratio": "16:9",
  "n": 1,
  "response_format": "url",
  "prompt_optimizer": false
}

响应:

{
  "id": "task_id",
  "data": {
    "image_urls": ["https://..."]
  },
  "metadata": {
    "success_count": "1"
  },
  "base_resp": {
    "status_code": 0,
    "status_msg": "success"
  }
}

注意事项

  1. API Key: 需要在 https://platform.minimaxi.com 开通 Coding Plan 并获取 API Key
  2. 生成数量: n 取值范围 [1, 9]
  3. 图片尺寸: 自定义宽高时,范围 [512, 2048],必须是 8 的倍数
  4. URL 有效期: 返回的 URL 有效期为 24 小时
  5. 图生图: 使用 --input-image 参数指定输入图片 URL

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.