Skip to main content
skill CX Codex

image-gen · nicknisi — Claude Code skill for image generation

image-gen is a Claude Code skill that generates or edits images with Gemini or OpenAI. It handles illustrations, diagrams, and graphics with readable labels.

MIT ★ 114 updated 2026-08-11

Install into Claude Code · Plugin marketplace All methods and platforms ↓
/plugin marketplace add nicknisi/claude-plugins
/plugin install image-gen@nicknisi
Open on GitHub

What image-gen does

The skill sends image generation and editing requests to Gemini (nano-banana-pro) or OpenAI gpt-image-2. Gemini handles illustrations and quick diagrams; OpenAI is the choice when rendered text matters or an edit needs a mask. It can combine multiple input images and supports 1K, 2K, and 4K output.

A bundled Node script, generate_image.js, performs the work, so there is no separate dependency installation. You need a provider API key: Gemini reads GEMINI_API_KEY or GOOGLE_API_KEY, while OpenAI reads OPENAI_API_KEY. Without the matching key, the provider request cannot run. Check the script’s available options with --help.

What it helps with

  • generate an illustration from a prompt
  • edit an existing image with written directions
  • combine several source images into one composition
  • make a diagram with legible labels

Example prompts for the agent

  • Create an illustration for this page and save it as output.png.
  • Edit input.png by adding labels, then save the result as output.png.
  • Make a diagram with readable labels and use OpenAI for image generation.

How to install image-gen

1Plugin marketplace

/plugin marketplace add nicknisi/claude-plugins
/plugin install image-gen@nicknisi

This installs the whole image-gen plugin with all its skills

2Skills CLI (Vercel)

npx skills add nicknisi/claude-plugins --skill image-gen -a claude-code

3Manually: put the files in place

~/.claude/skills/image-gen/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/image-gen/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about image-gen

How do I install image-gen in Claude Code?

In Claude Code, add the marketplace with /plugin marketplace add nicknisi/claude-plugins, then install the skill with /plugin install image-gen@nicknisi.

What does image-gen do?

It creates images from prompts and edits existing images through Gemini or OpenAI. Choose OpenAI when accurate text in the image matters.

Which API key does image-gen need?

Gemini uses GEMINI_API_KEY or GOOGLE_API_KEY; OpenAI uses OPENAI_API_KEY. The --api-key option can override the environment key.

Source text

SKILL.md · MIT
---
name: image-gen
description: >-
  Generate or edit images via Google Gemini (nano-banana-pro) or OpenAI
  gpt-image-2. Trigger on "generate image", "create diagram", "edit image",
  or "make illustration". Supports 1K/2K/4K resolution, masked inpainting,
  and text-accurate generation.
---

# Image Generation & Editing

Multi-provider image generation. Default provider is Gemini (nano-banana-pro); pass `--provider openai` to use gpt-image-2.

## Which provider to pick

- **Gemini (default):** general illustrations, quick diagrams, visual imagery. Accepts `--input-image` repeatedly for multi-image composition.
- **OpenAI:** anything where text rendering matters (infographics, slide-like images, dense-label diagrams, logos with text), or when you need masked inpainting on edits.

## Usage

The skill ships a pre-bundled Node script — no tsx or dependency install needed. The script's `--help` is the authoritative flag reference; run it rather than guessing:

```bash
node ${CLAUDE_PLUGIN_ROOT}/skills/image-gen/dist/generate_image.js --help
```

Generate:

```bash
node ${CLAUDE_PLUGIN_ROOT}/skills/image-gen/dist/generate_image.js \
  --prompt "your description" --filename "output.png"
```

Edit (image-to-image):

```bash
node ${CLAUDE_PLUGIN_ROOT}/skills/image-gen/dist/generate_image.js \
  --prompt "editing instructions" --filename "output.png" \
  --input-image "path/to/input.png"
```

## API keys

Read from the environment unless `--api-key` overrides: Gemini uses `GEMINI_API_KEY` or `GOOGLE_API_KEY`; OpenAI uses `OPENAI_API_KEY`. If only `OPENAI_API_KEY` is set, the provider defaults to OpenAI.

## Conventions

- Name files `YYYY-MM-DD-HH-MM-SS-descriptive-name.png`.
- For blog diagrams, use OpenAI at `2K` — anything with readable labels or callouts needs its text fidelity. Save to the post's content dir (e.g. `src/content/blog/post-name/`) and prefer clean, minimalist styles.
- The script prints the saved path. Report that path to the user; do not read the image back.

© Nick Nisi · MIT · nicknisi/claude-plugins

Similar skills

All skills for Design →

image-gen by other authors comes first.

image-gen marswaveai The image-gen skill turns a text description into an image through the ListenHub CLI, with a choice of model, resolution, aspect ratio and references. CX Codex +1 1,200installs image-gen dotslashsimran The image-gen Claude Code skill generates and edits images from requests. It activates for illustrations, icons, thumbnails, textures, and image series that need a consistent subject. CX Codex +1 ★ 541repo stars image-gen krishagel image-gen is a skill for Claude Code that creates images, infographics, and diagrams with Nano Banana 2 or edits an existing picture from a text prompt. CX Codex +1 4installs skill-image-gen official adamd9 skill-image-gen generates images from text prompts directly inside your editor. Useful when building game sprites, app icons, and mockups during coding. ★ 41,430repo stars Image Gen nuver-labs Image Gen lets coding agents produce and modify local image assets via Gemini and OpenAI. Helpful whenever a workflow requires UI mockups, logos, or banner drafts. CX Codex +1 ★ 1repo stars baoyu-image-gen JimLiu baoyu-image-gen — a skill that generates images via OpenAI, Google, Azure, OpenRouter, DashScope and ten other APIs. CX Codex +1 34,500installs seo-image-gen AgriciDaniel seo-image-gen — a skill for Claude Code, Codex, and Cursor builds search-optimized visuals via Gemini. Automates OG cards, blog hero banners, infographics, and clean product shots with preset aspect ratios. CX Codex +1 7,100installs canghe-image-gen freestylefly canghe-image-gen generates AI images via OpenAI, Google, DashScope, and Canghe APIs. Handles text prompts, aspect ratios, and reference files right inside coding agents. CX Codex +1 606installs openai-image-gen steipete openai-image-gen — a skill for Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, and OpenCode: calls the OpenAI Images API, renders a batch of images from structured prompts, and builds an HTML gallery. CX Codex +1 1installs

From the same set18

The whole set →
handoff Turns a working session into a short handoff file, so a fresh agent can pick up unfinished work without rebuilding the context. CX Codex +1 ★ 114repo stars squad-review squad-review runs six specialist code reviews on a branch diff, then tests every reported issue with an adversarial verifier. CX Codex +1 ★ 114repo stars socratic-tutor The socratic-tutor skill turns a code review into a guided understanding check, asking about the problem, solution, edge cases, and downstream impact. CX Codex +1 ★ 114repo stars thermo-nuclear-code-quality-review thermo-nuclear-code-quality-review conducts a ruthless maintainability audit on feature branches. Flags tangled logic, oversized files, and opportunities to cut structural bloat. CX Codex ★ 114repo stars explain-diff The explain-diff skill turns a diff, PR, branch, or commit into an HTML guide with system context, diagrams, a code walkthrough, and a quiz. Use it to understand a change or teach it to someone else. CX Codex +1 ★ 114repo stars code-simplifier code-simplifier refactors complex functions, cuts redundancy, and removes AI slop without touching public APIs or changing runtime behavior. CX Codex ★ 114repo stars git-committer The git-committer subagent reviews repository changes, runs available checks, and creates commits with semantic messages. Use it to hand off the commit workflow to Claude Code. CX Codex ★ 114repo stars tighten-prose tighten-prose strips the habits readers spot as machine-written — word clusters, inflated importance, phantom citations — and rewrites the flagged passages while keeping the author's voice. CX Codex +1 ★ 114repo stars

Project sponsors

Companies that keep this analytics open