Agent skill

Gpt Image Skill

by feiskyer in feiskyer/claude-code-settings

Generate or edit images using OpenAI GPT Image API (gpt-image-2, gpt-image-1, etc).

MITAuto-check passedMedia & Creative

Install Gpt Image Skill

skills CLI
$ npx skills add feiskyer/claude-code-settings --skill gpt-image-skill -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install feiskyer/claude-code-settings gpt-image-skill --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/feiskyer/claude-code-settings.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/gpt-image-skill .claude/skills/gpt-image-skill && rm -rf skills-src

Use ~/.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/

Facts

Skill name
gpt-image-skill
GitHub stars
1.7k
Token cost
~1.4k tokens
SKILL.md length
426 words
Files
4
Skills in repo
12
Repo updated
First seen
Licence
MIT

At a glance

Generate or edit images using OpenAI GPT Image API (gpt-image-2, gpt-image-1, etc).

  • Works in 4 steps: OPENAI_API_KEY: Must be configured in… → OPENAI_API_BASE (optional): Custom API… → Python3 with dependencies: openai,… → …
  • Explicitly names OpenAI
  • SKILL.md covers Requirements, Instructions, Available Options and Examples, plus 2 more sections
  • Runs Python scripts from its folder; calls python3; needs OPENAI_API_KEY

What it does

Gpt Image Skill is an agent skill from feiskyer/claude-code-settings. Generate or edit images using OpenAI GPT Image API (gpt-image-2, gpt-image-1, etc). Use ONLY when the user explicitly names OpenAI or GPT as the provider: "gpt image", "openai image", "generate image with openai", "用 openai 画图", "用 GPT 生成图片". For generic image requests without a provider, use nanobanana-skill instead. Do NOT use for diagrams (架构图/流程图) — draw those with Mermaid or code.

Its SKILL.md is about 1.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files (for example `evals/evals.json` and `gpt_image.py`).

It sits in Media & Creative, covering Image generation and Diagrams. It works with OpenAI, Mermaid and Python. The repository describes itself as: Curated skills, sub-agents, and config templates that supercharge Claude Code — research, image gen, GitHub automation & more. The licence is MIT.

When your agent uses it

  • Explicitly names OpenAI
  • GPT as the provider: gpt image
  • Generate image with openai
  • Diagrams (架构图/流程图) — draw those with Mermaid

Example prompts

  • “gpt image”
  • “openai image”
  • “generate image with openai”
  • “/gpt-image-skill”

Requirements

  • Python 3
  • A credential in OPENAI_API_KEY
  • Pre-approved tools (allowed-tools): Read, Write, Glob, Grep, Task, Bash(cat:*), Bash(ls:*), Bash(tree:*), Bash(python3:*)

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. OPENAI_API_KEY: Must be configured in ~/.gpt-image.env or export OPENAI_API_KEY=
  2. OPENAI_API_BASE (optional): Custom API base URL for compatible endpoints (e.g. Azure OpenAI, proxies). Set in ~/.gpt-image.env or export it.
  3. Python3 with dependencies: openai, Pillow. Install via python3 -m pip install -r ${CLAUDE_SKILL_DIR}/requirements.txt if not installed yet.
  4. Executable: ${CLAUDE_SKILL_DIR}/gpt_image.py

What it can do on your machine

Read from SKILL.md and the folder at commit 95dab59. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Glob
    • Grep
    • Task
    • Bash(cat:*)
    • Bash(ls:*)
    • Bash(tree:*)
    • Bash(python3:*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships script files (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python3

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • OPENAI_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Gpt Image Skill loads about 1.4k tokens when it runs. Until then it costs about 101 tokens; SKILL.md has 426 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~101
When it runs · the whole SKILL.md, loaded when a task matches
~1.4k

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.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

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); files beside SKILL.md are not scanned.

SKILL.md

The full file from feiskyer/claude-code-settings at commit 95dab59, republished under its MIT licence (© feiskyer). 426 words, ~1,367 tokens.

Download SKILL.mdSave it as .claude/skills/gpt-image-skill/SKILL.md (or your agent's skills folder). This skill also uses 3 other files; get the full folder from GitHub.
name
gpt-image-skill
description
Generate or edit images using OpenAI GPT Image API (gpt-image-2, gpt-image-1, etc). Use ONLY when the user explicitly names OpenAI or GPT as the provider: "gpt image", "openai image", "generate image with openai", "用 openai 画图", "用 GPT 生成图片". For generic image requests without a provider, use nanobanana-skill instead. Do NOT use for diagrams (架构图/流程图) — draw those with Mermaid or code.
allowed-tools
Read, Write, Glob, Grep, Task, Bash(cat:*), Bash(ls:*), Bash(tree:*), Bash(python3:*)

GPT Image Skill

Generate or edit images using OpenAI's GPT Image models through a bundled Python script.

Requirements

  1. OPENAI_API_KEY: Must be configured in ~/.gpt-image.env or export OPENAI_API_KEY=<your-key>
  2. OPENAI_API_BASE (optional): Custom API base URL for compatible endpoints (e.g. Azure OpenAI, proxies). Set in ~/.gpt-image.env or export it.
  3. Python3 with dependencies: openai, Pillow. Install via python3 -m pip install -r ${CLAUDE_SKILL_DIR}/requirements.txt if not installed yet.
  4. Executable: ${CLAUDE_SKILL_DIR}/gpt_image.py

Instructions

For image generation
  1. Ask the user for:

    • What they want to create (the prompt)
    • Desired size (optional, defaults to 1024x1024)
    • Output filename (optional, auto-generates UUID-based name if not specified)
    • Model preference (optional, defaults to gpt-image-2)
    • Quality (optional, defaults to auto)
    • Number of images (optional, defaults to 1)
  2. Run the script:

    bash
    python3 ${CLAUDE_SKILL_DIR}/gpt_image.py --prompt "description of image" --output "filename.png"
  3. Show the user the saved image path when complete.

For image editing
  1. Ask the user for:

    • Input image file(s) to edit (up to 3)
    • What changes they want (the prompt)
    • Output filename (optional)
  2. Run with input images:

    bash
    python3 ${CLAUDE_SKILL_DIR}/gpt_image.py edit --prompt "editing instructions" --input image1.png image2.png --output "edited.png"

Available Options

Models (--model)
  • gpt-image-2 (default) — Latest model with strong instruction following, text rendering, and broad world knowledge
  • gpt-image-1.5 — Mid-tier model
  • gpt-image-1 — First-generation GPT image model
  • gpt-image-1-mini — Lightweight, faster generation
Sizes (--size)
  • 1024x1024 (default) — Square
  • 1024x1536 — Portrait (2:3)
  • 1536x1024 — Landscape (3:2)
  • auto — Let the model decide
Quality (--quality)
  • auto (default) — Model decides optimal quality
  • high — Higher detail, slower
  • medium — Balanced
  • low — Fastest
Output Format (--format)
  • png (default) — Lossless
  • jpeg — Smaller file size
  • webp — Modern format, good compression
Background (--background)
  • auto (default) — Model decides
  • transparent — Transparent background (png/webp only)
  • opaque — Solid background
Show full SKILL.md (173 more words)Show less
Other Options
  • --n <count> — Number of images to generate (default: 1)
  • --output <filename> — Output filename (default: auto-generated)

Examples

Generate a simple image
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py --prompt "A serene mountain landscape at sunset with a lake"
Generate with specific size and output
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py \
  --prompt "Modern minimalist logo for a tech startup" \
  --size 1024x1024 \
  --quality high \
  --output "logo.png"
Generate landscape image
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py \
  --prompt "Futuristic cityscape with flying cars" \
  --size 1536x1024 \
  --output "cityscape.png"
Generate with transparent background
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py \
  --prompt "A cute cartoon cat mascot" \
  --background transparent \
  --format png \
  --output "mascot.png"
Generate multiple images
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py \
  --prompt "Abstract art in the style of Kandinsky" \
  --n 3 \
  --output "art.png"
Edit existing images
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py edit \
  --prompt "Add a rainbow in the sky" \
  --input photo.png \
  --output "photo-with-rainbow.png"
Combine multiple reference images
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py edit \
  --prompt "Create a gift basket containing all items shown" \
  --input item1.png item2.png item3.png \
  --output "gift-basket.png"
Use a different model
bash
python3 ${CLAUDE_SKILL_DIR}/gpt_image.py \
  --prompt "Detailed portrait of a cat in watercolor style" \
  --model gpt-image-1 \
  --output "cat-portrait.png"

Error Handling

If the script fails:

  • Check that OPENAI_API_KEY is exported
  • If using a custom endpoint, verify OPENAI_API_BASE is correct
  • Verify input image files exist and are readable (for editing)
  • Ensure the output directory is writable
  • Check that the model name is valid

Best Practices

  1. Be descriptive in prompts — include style, mood, colors, composition details
  2. For logos/icons, use square size (1024x1024) with transparent background
  3. For social media, use portrait (1024x1536) for stories or square for posts
  4. For wallpapers/headers, use landscape (1536x1024)
  5. Use high quality for final output, auto for quick iterations
  6. GPT Image models excel at text rendering — include text in prompts when needed
  7. For editing, provide clear instructions about what to change and what to keep

© feiskyer, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 3 other files in skills/gpt-image-skill of feiskyer/claude-code-settings.

  • SKILL.md
  • evals/evals.json
  • gpt_image.py
  • requirements.txt

Open the folder on GitHubat commit 95dab59

Compare with similar skills

Gpt Image Skill 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.

Gpt Image Skill compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Gpt Image Skill this skillfeiskyer/claude-code-settings1.7k—~1.4kAutomated safety check: PassMIT
Draw Image DiagramsRealSeaberry/AutoMCM-Pro257—~1.9kAutomated safety check: NotesMIT
Sf Diagram NanobananaproJaganpro/sf-skills424—~1.6kAutomated safety check: PassMIT
Generate ImageK-Dense-AI/claude-scientific-writer2.4k1 repos~3.8kAutomated safety check: NotesMIT
Gpt Image Skillfeiskyer/codex-settings244—~572Automated safety check: PassMIT
Paper Figure GenerateGRIND-Lab-Core/night_owl_research_agent106—~5.1kAutomated safety check: NotesNone

Similar skills

  • Draw Image Diagrams

    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.

    257 GitHub stars~1.9k tokensUpdated 29 days ago
    Media & CreativeAuto-check: notes
  • Sf Diagram Nanobananapro

    Jaganpro/sf-skills

    AI-powered image generation for Salesforce visuals via Nano Banana Pro.

    424 GitHub stars~1.6k tokensUpdated 5 mo ago
    Media & CreativeAuto-check passed
  • Generate Image

    K-Dense-AI/claude-scientific-writer

    Generate or edit images with AI models through the OpenRouter Image API (Gemini, Seedream, Recraft, GPT-Image, Riverflow).

    2.4k GitHub starsUsed in 1 repo~3.8k tokens
    Media & CreativeAuto-check: notes
  • Gpt Image Skill

    feiskyer/codex-settings

    Generate or edit images when the user names OpenAI, GPT Image, or a gpt-image model.

    244 GitHub stars~572 tokensUpdated 12 days ago
    Media & CreativeAuto-check passed
  • Paper Figure Generate

    GRIND-Lab-Core/night_owl_research_agent

    Generates publication-quality figures and diagrams from output/PAPERPLAN.md for GIScience, GeoAI, and remote sensing journals (IJGIS, ISPRS JPRS, RSE, TGIS).

    106 GitHub stars~5.1k tokensUpdated 5 mo ago
    Media & CreativeAuto-check: notes
  • 2D Map and Scene Generator

    0x0funky/agent-sprite-forge

    Plans and builds 2D game maps and scenes, from tilemaps and parallax backgrounds to HD-2D plates, with collision checks, a playable HTML preview and Tiled, Godot or LDtk export.

    4.4k GitHub stars~2.9k tokensUpdated 3 days ago
    Game DevelopmentAuto-check passed

More from feiskyer/claude-code-settings

All 12 skills in this repo
  • Skill Creator

    feiskyer/claude-code-settings

    Create, refine, and benchmark agent skills. An agent skill from feiskyer/claude-code-settings.

    1.7k GitHub stars~7.6k tokensUpdated 12 days ago
    Auto-check passed
  • Brainstorming

    feiskyer/claude-code-settings

    Explore user intent, requirements, and design options through collaborative dialogue before implementation.

    1.7k GitHub stars~985 tokensUpdated 12 days ago
    Auto-check passed
  • Deep Research

    feiskyer/claude-code-settings

    Multi-agent research orchestration: split a research goal into parallel sub-goals, run each via headless claude -p subprocesses, aggregate results into a polished report file.

    1.7k GitHub stars~2.6k tokensUpdated 12 days ago
    Auto-check: notes
  • Codex Skill

    feiskyer/claude-code-settings

    Leverage OpenAI Codex/GPT models for autonomous code implementation, code review, and plan review.

    1.7k GitHub stars~2.7k tokensUpdated 12 days ago
    Auto-check: warnings
  • GitHub Fix Issue

    feiskyer/claude-code-settings

    Fix GitHub issues end-to-end — analysis, branch creation, implementation, testing, and PR submission.

    1.7k GitHub stars~786 tokensUpdated 12 days ago
    Auto-check passed
  • GitHub Review PR

    feiskyer/claude-code-settings

    Review GitHub pull requests with detailed, multi-perspective code analysis using parallel subagents.

    1.7k GitHub stars~9.2k tokensUpdated 12 days ago
    Auto-check passed

Questions about Gpt Image Skill

What does Gpt Image Skill do?

Generate or edit images using OpenAI GPT Image API (gpt-image-2, gpt-image-1, etc). Gpt Image Skill is an agent skill from feiskyer/claude-code-settings. Generate or edit images using OpenAI GPT Image API (gpt-image-2, gpt-image-1, etc).

When should I use Gpt Image Skill?

Gpt Image Skill fits situations like: explicitly names OpenAI; GPT as the provider: gpt image; generate image with openai; diagrams (架构图/流程图) — draw those with Mermaid.

How do I install Gpt Image Skill in Claude Code?

Run `npx skills add feiskyer/claude-code-settings --skill gpt-image-skill -a claude-code`. Or copy the skill folder (skills/gpt-image-skill in feiskyer/claude-code-settings) into .claude/skills/gpt-image-skill in your project. Claude Code loads it when a task matches its description.

How do I install Gpt Image Skill in Codex?

Run `npx skills add feiskyer/claude-code-settings --skill gpt-image-skill -a codex`. Or copy the skill folder (skills/gpt-image-skill in feiskyer/claude-code-settings) into .agents/skills/gpt-image-skill in your project. Codex loads it when a task matches its description.

Can I use Gpt Image Skill in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add feiskyer/claude-code-settings --skill gpt-image-skill -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-skill, .gemini/skills/gpt-image-skill, .github/skills/gpt-image-skill and .opencode/skills/gpt-image-skill in your project.

What does Gpt Image Skill need to run?

Going by SKILL.md and its folder, Gpt Image Skill needs Python for the scripts in its folder, the command-line tools its instructions call (python3) and credentials named OPENAI_API_KEY. Our summary lists: Python 3; A credential in OPENAI_API_KEY. Its frontmatter pre-approves these tools: Read, Write, Glob, Grep, Task, Bash(cat:*), Bash(ls:*), Bash(tree:*), Bash(python3:*).

Does Gpt Image Skill access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Gpt Image Skill safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Gpt Image Skill use?

Gpt Image Skill is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Gpt Image Skill use?

About 1.4k tokens (SKILL.md is roughly 5.5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Gpt Image Skill?

Skills that share tags, products or a category with Gpt Image Skill: Draw Image Diagrams (RealSeaberry/AutoMCM-Pro, 257 stars), Sf Diagram Nanobananapro (Jaganpro/sf-skills, 424 stars), Generate Image (K-Dense-AI/claude-scientific-writer, 2.4k stars) and Gpt Image Skill (feiskyer/codex-settings, 244 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Gpt Image Skill?

feiskyer (a GitHub user) maintains it in feiskyer/claude-code-settings, which has 1,658 GitHub stars. The repository holds 12 skills in this directory. The repository was last updated on September 27, 2026.

Source: feiskyer/claude-code-settings on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.