Main Site ↗

openai-image-gen

by clawdbot340.2k778GitHub

A Python script that generates multiple images using OpenAI's image models with configurable parameters. It creates random structured prompts, supports batch generation, and outputs an HTML gallery for easy viewing. Handles different models (GPT image, DALL-E 2/3) with appropriate defaults and limitations.

Unlock Deep Analysis

Use AI to visualize the workflow and generate a realistic output preview for this skill.

Powered by Fastest LLM

Target Audience

Developers and designers who need to batch-generate AI images for prototyping, content creation, or testing different model parameters

10/10Security

Low security risk, safe to use

8
Clarity
7
Practicality
8
Quality
6
Maintainability
5
Innovation
AI/ML
image-generationopenai-apibatch-processinggallery-viewer
Compatible Agents
Claude Code
Claude Code
~/.claude/skills/
Codex CLI
Codex CLI
~/.codex/skills/
Gemini CLI
Gemini CLI
~/.gemini/skills/
O
OpenCode
~/.opencode/skills/
O
OpenClaw
~/.openclaw/skills/
GitHub Copilot
GitHub Copilot
~/.copilot/skills/
Cursor
Cursor
~/.cursor/skills/
W
Windsurf
~/.codeium/windsurf/skills/
C
Cline
~/.cline/skills/
R
Roo Code
~/.roo/skills/
K
Kiro
~/.kiro/skills/
J
Junie
~/.junie/skills/
A
Augment Code
~/.augment/skills/
W
Warp
~/.warp/skills/
G
Goose
~/.config/goose/skills/
SKILL.md

OpenAI Image Gen

Generate a handful of “random but structured” prompts and render them via OpenAI Images API.

Setup

  • Needs env: OPENAI_API_KEY

Run

From any directory (outputs to ~/Projects/tmp/... when present; else ./tmp/...):

python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py
open ~/Projects/tmp/openai-image-gen-*/index.html

Useful flags:

python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py --count 16 --model gpt-image-1.5
python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py --prompt "ultra-detailed studio photo of a lobster astronaut" --count 4
python3 ~/Projects/agent-scripts/skills/openai-image-gen/scripts/gen.py --size 1536x1024 --quality high --out-dir ./out/images

Output

  • *.png images
  • prompts.json (prompt ↔ file mapping)
  • index.html (thumbnail gallery)

Source: https://github.com/clawdbot/clawdbot#skills~openai-image-gen

Content curated from original sources, copyright belongs to authors

Grade A
7.1AI Score
Best Practices
Checking...
Try this Skill

User Rating

USER RATING

0UP
0DOWN
Loading files...

WORKS WITH

Claude Code
Claude
Codex CLI
Codex
Gemini CLI
Gemini
O
OpenCode
O
OpenClaw
GitHub Copilot
Copilot
Cursor
Cursor
W
Windsurf
C
Cline
R
Roo
K
Kiro
J
Junie
A
Augment
W
Warp
G
Goose