Gpt Image
nikships/droidproxy
Generate or edit images via GPT Image 2.5 Flare or Sunburst through DroidProxy Codex OAuth (no OPENAIAPIKEY).
生图 / 生成图片 / 画图 — 用 OpenAI gpt-image-2 生成图像。支持文生图、参考图生图 (img2img)、蒙版修补 (inpainting)。当用户要求用 GPT 画图、OpenAI 生图、gpt-image-2、文+图生图、参考图片生成、img2img、inpainting 时必加载此技能。Auth 自动继承 OPENAIAPIKEY / Codex OAuth…
$ npx skills add ninehills/skills --skill gpt-image-gen -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install ninehills/skills gpt-image-gen --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/ninehills/skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/gpt-image-gen .claude/skills/gpt-image-gen && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "gpt-image-gen" agent skill from https://github.com/ninehills/skills/tree/main/gpt-image-gen into .claude/skills/gpt-image-gen/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "gpt-image-gen", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/ninehills/skills/tree/main/gpt-image-genType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add ninehills/skills --skill gpt-image-gen -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install ninehills/skills gpt-image-gen --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ninehills/skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/gpt-image-gen .agents/skills/gpt-image-gen && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "gpt-image-gen" agent skill from https://github.com/ninehills/skills/tree/main/gpt-image-gen into .agents/skills/gpt-image-gen/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "gpt-image-gen", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add ninehills/skills --skill gpt-image-gen -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install ninehills/skills gpt-image-gen --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ninehills/skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/gpt-image-gen .cursor/skills/gpt-image-gen && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "gpt-image-gen" agent skill from https://github.com/ninehills/skills/tree/main/gpt-image-gen into .cursor/skills/gpt-image-gen/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "gpt-image-gen", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/ninehills/skills.git --path gpt-image-gen--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add ninehills/skills --skill gpt-image-gen -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install ninehills/skills gpt-image-gen --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ninehills/skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/gpt-image-gen .gemini/skills/gpt-image-gen && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "gpt-image-gen" agent skill from https://github.com/ninehills/skills/tree/main/gpt-image-gen into .gemini/skills/gpt-image-gen/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "gpt-image-gen", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install ninehills/skills gpt-image-genInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add ninehills/skills --skill gpt-image-gen -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/ninehills/skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/gpt-image-gen .github/skills/gpt-image-gen && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "gpt-image-gen" agent skill from https://github.com/ninehills/skills/tree/main/gpt-image-gen into .github/skills/gpt-image-gen/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "gpt-image-gen", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add ninehills/skills --skill gpt-image-gen -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install ninehills/skills gpt-image-gen --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ninehills/skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/gpt-image-gen .opencode/skills/gpt-image-gen && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "gpt-image-gen" agent skill from https://github.com/ninehills/skills/tree/main/gpt-image-gen into .opencode/skills/gpt-image-gen/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "gpt-image-gen", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
gpt-image-gen生图 / 生成图片 / 画图 — 用 OpenAI gpt-image-2 生成图像。支持文生图、参考图生图 (img2img)、蒙版修补 (inpainting)。当用户要求用 GPT 画图、OpenAI 生图、gpt-image-2、文+图生图、参考图片生成、img2img、inpainting 时必加载此技能。Auth 自动继承 OPENAIAPIKEY / Codex OAuth…
Gpt Image Gen is an agent skill from ninehills/skills. 生图 / 生成图片 / 画图 — 用 OpenAI gpt-image-2 生成图像。支持文生图、参考图生图 (img2img)、蒙版修补 (inpainting)。当用户要求用 GPT 画图、OpenAI 生图、gpt-image-2、文+图生图、参考图片生成、img2img、inpainting 时必加载此技能。Auth 自动继承 OPENAIAPIKEY / Codex OAuth (Pi/Codex) / .env / config.yaml。
Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. The skill folder holds 8 other files, including scripts and reference files (for example `references/architecture.md`, `references/auth-pitfalls.md` and `references/codex-backend.md`).
It sits in Media & Creative, covering Image generation and LLM API integration. It works with OpenAI. The licence is MIT.
7 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit f3e82a7. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships 1 file in scripts/ (Python), which the agent can run.
Shell commands in SKILL.md call:
python3pipFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use pip, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
OPENAI_API_KEYFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Gpt Image Gen loads about 1.8k tokens when it runs, and up to ~13k if it reads all its reference files. Until then it costs about 61 tokens; SKILL.md has 542 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
PENAI_API_KEY / Codex OAuth (Pi/Codex) / .env / config.yaml。"- `python-dotenv`:自动加载 `./.env` 和 `~/.env`(可选,没有也能用)2. `./.env` 文件(当前目录)3. `~/.env` 文件(家目录)Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.
The full file from ninehills/skills at commit f3e82a7, republished under its MIT licence (© ninehills). 542 words, ~1,754 tokens.
.claude/skills/gpt-image-gen/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.调用 OpenAI gpt-image-2 模型生图。单一脚本覆盖三种模式:
| 模式 | 触发条件 | 后端 |
|---|---|---|
| 文生图 | 仅 -p | API key → images.generate / Codex OAuth → Responses API |
| 参考图编辑 | -p + -i | API key → images.edit / Codex OAuth → Responses API (input_image) |
| 蒙版修补 | -p + -i + -m | 仅 API key → images.edit;Codex 不支持 |
Auth 自动选择: 检测到 JWT token (eyJ...) 时走 Codex Responses API (chatgpt.com/backend-api/codex),否则走标准 OpenAI REST API (api.openai.com)。
只要用户提到以下任一关键词/场景,立即加载:
特别注意: 如果用户发送了图片附件并说「用这个图生成」「基于这张图」「把这张图改成」等,这就是 img2img 场景——必须加载此技能,因为内置 image_generate 不支持图片输入。
pip install openai python-dotenvopenai:API 调用python-dotenv:自动加载 ./.env 和 ~/.env(可选,没有也能用)脚本按以下优先级找 API key:
OPENAI_API_KEY 环境变量./.env 文件(当前目录)~/.env 文件(家目录)~/.pi/agent/auth.json → openai-codex.access)hermes auth codex 登录过的)config.yaml → image_gen.openai.api_key--api-key 手动传入⚠️ Codex token 限制: Codex OAuth token/pi auth token 只能认证 chatgpt.com/backend-api/codex,不能直连 api.openai.com。如果 auth 解析落到 Codex token(优先级 4-5),脚本会拿它当标准 API key 去打 api.openai.com/v1/images/*,返回 401 Missing scopes: api.model.images.request。文生图请用 Hermes 内置 image_generate 工具(走 Codex backend);img2img / inpainting(images.edit)必须有真正的 OPENAI_API_KEY。详见 references/auth-pitfalls.md。
python3 scripts/gen.py -p "a cat astronaut on the moon" --quality high
# 多张
python3 scripts/gen.py -p "..." -n 4# 单参考图
python3 scripts/gen.py -p "make it cyberpunk style" -i photo.jpg
# 多参考图
python3 scripts/gen.py -p "collab poster" -i cat.png -i logo.png -f out.png# opaque 区域保留,transparent 区域重绘
python3 scripts/gen.py -p "replace sky with aurora" -i photo.jpg -m sky_mask.pngpython3 scripts/gen.py -p "..." --size 2k --quality high --format webp --compression 85
python3 scripts/gen.py -p "..." --size 3840x2160 --quality high参考文件:references/templates.md(833 行,16 类工业级模板 + 防坑指南)。
工作流:Agent 读 templates.md → 匹配合适的模板类别 → 用模板结构组装完整 prompt → 调 gen.py 生图。
Agent 加载 skill 后,需按需读取 references/templates.md 全文或定位到相关章节。模板覆盖 UI、信息图、海报、电商、品牌、摄影、角色、历史、工业设计等 16 个类别,每类有标准模板 + 防坑指南。
Agent 的典型流程:
clarify 展示优化后的 prompt,等用户确认gen.py -p "<prompt>" --quality high如果用户给的 prompt 已经很详细,则跳过优化,直接调 gen.py。
⚠️ 强制确认规则:
clarify 展示修改后的完整 prompt 让用户确认,确认后才能调 gen.py| 参数 | 简写 | 类型 | 默认值 | 说明 |
|---|---|---|---|---|
--prompt | -p | str | 必填 | 提示词 |
--image | -i | path | — | 参考图,可重复传多个 |
--mask | -m | path | — | Alpha 通道蒙版 PNG(需配合 -i) |
--output | -f | path | 自动命名 | 输出文件路径 |
--n | -n | int | 1 | 生成张数 |
--model | str | gpt-image-2 | 模型 ID | |
--quality | -q | literal | high | 见下方质量策略 |
--size | -s | literal | 1024x1024 | 见下方尺寸表 |
--format | literal | png | png / jpeg / webp | |
--compression | int | — | 压缩级别 0-100(jpeg/webp) | |
--moderation | literal | low | low / auto | |
--background | literal | — | opaque / auto | |
--input-fidelity | literal | — | low / high(gpt-image-2 自动剔除) | |
--api-key | str | 自动解析 | 手动指定 API key | |
--json | flag | — | JSON 格式输出 | |
--verbose | -v | flag | — | 详细日志 |
| 快捷名 | 分辨率 | 适用场景 |
|---|---|---|
1k / square | 1024×1024 | 正方形,社交头像 |
2k | 2048×2048 | 高清印刷 |
4k | 3840×2160 | 宽屏电影级 |
landscape | 1536×1024 | 横版照片/游戏截图 |
portrait | 1024×1536 | 竖版海报/手机壁纸 |
wide | 2048×1152 | 宽幅横版 |
tall | 2160×3840 | 超长竖版 |
也支持自定义 WxH:--size 1536x1536。约束:16px 倍数,总像素 655,360 ~ 8,294,400,宽高比 ≤ 3:1。
| 质量 | 速度 | 成本(1024²) | 何时用 |
|---|---|---|---|
auto | 自适应 | 自适应 | 让 API 自行判断 |
low | ~15s | ~$0.006 | 快速草稿、批量探索、构图检查 |
medium | ~40s | ~$0.05 | 风格测试、日常浏览 |
high | ~2min | ~$0.21 | 中文字体、海报、信息图、正式交付 |
默认 high。Agent 应根据场景自动选档:探索用 low、风格尝试用 medium、最终交付用 high。
── PROMPT ── + prompt + ── IMAGE ── + 图片路径 + ── PARAMS ── + 参数 + prompt 文本~/.hermes/cache/images/(--output 可覆盖).prompt.txt 副文件,与图片同名、同路径,记录完整 prompt 和所有参数,方便复用--json 模式输出结构化 JSON| 码 | 含义 | 处理 |
|---|---|---|
| 0 | 成功 | 输出路径到 stdout |
| 1 | API 错误 | 检查 moderation/rate-limit/content-policy 返回信息 |
| 2 | 参数错误 | 缺少 API key、mask 无 image、n<1 等 |
gpt-image-1.5)--input-fidelity 在 gpt-image-2 上会自动剔除(模型拒绝该参数)--moderation 仅适用于 images.generate,images.edit 路径自动剔除--mask 蒙版修补、不支持 -n 多张--mask 必须是带 alpha 通道的 PNG,opaque=保留,transparent=重绘references/codex-backend.md~/.hermes/image_cache/img_*.jpegreferences/test-report.mdvision_analyze 失败,gen.py -i 的 img2img 仍然正常工作。Agent 无需先「看懂」图片即可做参考图编辑——图像模型独立处理视觉理解。若确实需要了解原图内容来写 prompt,可用 PIL 做颜色/边缘分析辅助判断构图。<|end▁of▁thinking|><||DSML||parameter name="old_string" string="true">## 注意事项
gpt-image-1.5)--input-fidelity 在 gpt-image-2 上会自动剔除(模型拒绝该参数)--moderation 仅适用于 images.generate,images.edit 路径自动剔除--mask 蒙版修补、不支持 -n 多张--mask 必须是带 alpha 通道的 PNG,opaque=保留,transparent=重绘references/codex-backend.md~/.hermes/image_cache/img_*.jpegreferences/test-report.md© ninehills, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 6 other files (scripts, references) in gpt-image-gen of ninehills/skills.
Open the folder on GitHubat commit f3e82a7
Gpt Image Gen next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Gpt Image Gen this skillninehills/skills | 280 | — | ~1.8k | Automated safety check: Notes | MIT | |
| Gpt Imagenikships/droidproxy | 122 | — | ~2.5k | Automated safety check: Pass | MIT | |
| Talking Avatar Voice Chat Appbuildfastwithai/gen-ai-experiments | 785 | — | ~1.7k | Automated safety check: Pass | MIT | |
| Draw Image DiagramsRealSeaberry/AutoMCM-Pro | 257 | — | ~1.9k | Automated safety check: Notes | MIT | |
| Inno Figure GenOpenLAIR/dr-claw | 1.2k | — | ~2.4k | Automated safety check: Pass | Custom licence | |
| Codex Imagendarkamenosa/codex-imagen | 135 | — | ~2.6k | Automated safety check: Pass | MIT |
nikships/droidproxy
Generate or edit images via GPT Image 2.5 Flare or Sunburst through DroidProxy Codex OAuth (no OPENAIAPIKEY).
buildfastwithai/gen-ai-experiments
Builds a realtime voice-chat app around a talking character portrait made from your photo or a text description, with mouth sprites driven by the audio.
RealSeaberry/AutoMCM-Pro
Generates diagrams, flowcharts and conceptual illustrations with OpenAI's gpt-image models, while leaving data plots and result figures to real plotting code.
OpenLAIR/dr-claw
Generate/edit images with OpenAI gpt-image-2 by default, falling back to Gemini (gemini-3.1-flash-image-preview) when OPENAIAPIKEY is unset.
darkamenosa/codex-imagen
Generate or edit raster images by calling the ChatGPT/Codex hosted imagegeneration flow with local Codex or OpenClaw OAuth credentials, then save decoded image files for OpenClaw and other agent…
evolution-foundation/evo-nexus
Generates PNG images through OpenRouter models, with transparent backgrounds and reference-image edits, and describes existing images with multimodal vision.
ninehills/skills
Market prediction skill using Kronos. An agent skill from ninehills/skills.
ninehills/skills
Track finance investment signal evolution and update logic based on new finance market information.
ninehills/skills
A skill your agent uses when the user wants to create any technical diagram - architecture, data flow, flowchart, sequence, agent/memory, or concept map - and export as SVG+PNG.
ninehills/skills
Analyze finance text sentiment using FinBERT or LLM. An agent skill from ninehills/skills.
ninehills/skills
把图片、截图、海报、PPT 页面截图、HTML 或 SVG 设计稿转换成可编辑 PPTX 的 Codex skill. An agent skill from ninehills/skills.
ninehills/skills
把一张或多张图片整理成 PSD 图层文件的创作与转换 skill。当用户需要 image2psd、图片转 PSD、 多张图片拼成 PSD、海报/设计稿拆成多个图层、白底转透明、颜色聚类拆层、把 Codex/AI 生图结果拆成元素图再合成 PSD、 或希望输出 layered PSD、可在 Photoshop/Photopea 中编辑的分层栅格文件时,应该使用此 skill。
Works with
生图 / 生成图片 / 画图 — 用 OpenAI gpt-image-2 生成图像。支持文生图、参考图生图 (img2img)、蒙版修补 (inpainting)。当用户要求用 GPT 画图、OpenAI 生图、gpt-image-2、文+图生图、参考图片生成、img2img、inpainting 时必加载此技能。Auth 自动继承 OPENAIAPIKEY / Codex OAuth…. Gpt Image Gen is an agent skill from ninehills/skills.
Gpt Image Gen fits situations like: tasks that involve Image generation; tasks that involve LLM API integration.
Run `npx skills add ninehills/skills --skill gpt-image-gen -a claude-code`. Or copy the skill folder (gpt-image-gen in ninehills/skills) into .claude/skills/gpt-image-gen in your project. Claude Code loads it when a task matches its description.
Run `npx skills add ninehills/skills --skill gpt-image-gen -a codex`. Or copy the skill folder (gpt-image-gen in ninehills/skills) into .agents/skills/gpt-image-gen in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add ninehills/skills --skill gpt-image-gen -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/gpt-image-gen, .gemini/skills/gpt-image-gen, .github/skills/gpt-image-gen and .opencode/skills/gpt-image-gen in your project.
Going by SKILL.md and its folder, Gpt Image Gen needs Python for the scripts in its folder, the command-line tools its instructions call (python3 and pip) and credentials named OPENAI_API_KEY. Our summary lists: Python 3; A credential in OPENAI_API_KEY.
SKILL.md contains no URLs. Its commands use pip, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Gpt Image Gen is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.8k tokens (SKILL.md is roughly 7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 11k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Gpt Image Gen: Gpt Image (nikships/droidproxy, 122 stars), Talking Avatar Voice Chat App (buildfastwithai/gen-ai-experiments, 785 stars), Draw Image Diagrams (RealSeaberry/AutoMCM-Pro, 257 stars) and Inno Figure Gen (OpenLAIR/dr-claw, 1.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
ninehills (a GitHub user) maintains it in ninehills/skills, which has 280 GitHub stars. The repository holds 38 skills in this directory. The repository was last updated on June 22, 2026.
Source: ninehills/skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.