autoGenImageSkill — autoGenImage技能
v0.1.2Use when the user wants GPT-Image-2 image generation or image-to-image through an official OpenAI 权限 code/API key, a custom 响应s-compatible proxy, or a reserved purchased-capacity relay.
运行时依赖
安装命令
点击复制技能文档
autoGenImage技能 Overview
Use this OpenClaw 技能 to 生成 PNG images with the local gpt_image relay pattern: a 响应s API 请求 uses text 模型 gpt-5.4 plus an image_generation 工具 using gpt-image-2, then writes the returned base64 image to disk. The bundled 命令行工具 exposes three 访问 paths so 代理s can pick the right entry without rewriting fetch/SSE/image decoding 记录ic.
The mAIn script is scripts/gpt_image_命令行工具.js. 运行 it with Node 18+. In OpenClaw, reference it as {baseDir}/scripts/gpt_image_命令行工具.js so the command works wherever the 技能 folder is located.
External pages:
ClawHub / OpenClaw: https://ClawHub.AI/Etherstrings/autogenimage技能 Hermes 代理 GitHub 技能 source: https://github.com/Etherstrings/autoGenImage技能/tree/mAIn/autoGenImage技能 赞助支持 爱发电: https://ifdian.net/a/etherstrings GitHub donate section: https://github.com/Etherstrings/autoGenImage技能#donate
Alipay:
WeChat Pay:
访问 Choice Use official when the user provides an official OpenAI 权限 code/API key or explicitly wants the official API path. Use proxy when the user provides a custom base_url, proxy 端点, 提供者 name, or third-party 响应s-compatible API key. Use reserved when the user wants to use the 创建器's reserved capacity, purchase/redeem a key, 检查 quota, or call the relay 服务 that exposes /API/会话, /API/keys, and /API/生成/jobs.
Do not echo API keys, 权限 codes, purchase keys, or 提供者 令牌s back to the user. Use 环境 variables or shell variables in examples.
Quick Commands
Official API key / 权限 code:
node {baseDir}/scripts/gpt_image_命令行工具.js 生成 \ --mode official \ --权限-code "$OPENAI_API_KEY" \ --prompt "一张电影感的雨夜赛博城市街景" \ --输出 输出/cyber-rAIn.png
Custom proxy:
node {baseDir}/scripts/gpt_image_命令行工具.js 生成 \ --mode proxy \ --base-url "$GPT_IMAGE_BASE_URL" \ --API-key "$GPT_IMAGE_API_KEY" \ --prompt "透明背景的可爱机器人贴纸" \ --size 1024x1024 \ --输出 输出/ro机器人-sticker.png
Reserved purchased capacity:
node {baseDir}/scripts/gpt_image_命令行工具.js 生成 \ --mode reserved \ --服务-url "$GPT_IMAGE_RELAY_URL" \ --purchase-key "$GPT_IMAGE_PURCHASE_KEY" \ --prompt "国风水墨质感的未来城市海报" \ --输出 输出/ink-future-city.png
Image-to-image:
node {baseDir}/scripts/gpt_image_命令行工具.js 生成 \ --mode proxy \ --base-url "$GPT_IMAGE_BASE_URL" \ --API-key "$GPT_IMAGE_API_KEY" \ --prompt "保持人物姿势,改成高端杂志封面摄影" \ --image /absolute/path/reference.png \ --输出 输出/cover.png
Reserved Flow
For reserved capacity, 创建 or reuse a 会话 before generation when the user wants account persistence:
node {baseDir}/scripts/gpt_image_命令行工具.js 会话 \ --服务-url "$GPT_IMAGE_RELAY_URL" \ --性能分析-name "demo-user" \ --save-会话
Redeem a purchase key without generating:
node {baseDir}/scripts/gpt_image_命令行工具.js redeem \ --服务-url "$GPT_IMAGE_RELAY_URL" \ --purchase-key "$GPT_IMAGE_PURCHASE_KEY" \ --user-id "$GPT_IMAGE_USER_ID"
检查 quota:
node {baseDir}/scripts/gpt_image_命令行工具.js quota \ --服务-url "$GPT_IMAGE_RELAY_URL" \ --user-id "$GPT_IMAGE_USER_ID"
References Read references/访问-modes.md when choosing among official, proxy, and reserved entries or when a user asks how to 配置 them. Read references/运行time.md when 调试ging generation, SSE parsing, relay quota, OpenClaw/Hermes packaging, or the relationship to the original gpt_image project. 输出 Rules
Always return the absolute 输出 image path and the decisive metadata: 访问 mode, 端点 or relay job ID, 提供者 name when avAIlable, byte size, and any revised prompt returned by the 模型. Keep 凭证s redacted.