image-gen

image-gen is a skill for Claude Code, Codex from SpillwaveSolutions/image_gen. It costs 61 tokens per session (1,543 once invoked), scanned A, original, MIT.

An image-generation helper for creating cover images, illustrations, and other visual assets for technical articles. It can use configured Imagen, Grok, or Codex image tools.

In plain words
What is it for?
Use it to create article covers, in-article illustrations, and supporting visual assets; it is not intended for Mermaid or PlantUML diagrams.
Why use it?
It provides a defined workflow for producing article visuals and can try another configured image tool when one fails.

Skill for Claude CodeCodex

Part of the image-gen plugin — 2 skills, 2 commands shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/spillwavesolutions/image_gen/image-gen
Any agent
npx skills add SpillwaveSolutions/image_gen --skill image-gen
Clone the repo
git clone --depth 1 https://github.com/SpillwaveSolutions/image_gen

Made for: Claude Code, Codex.

Or install image-gen, the plugin that ships this one along with the rest of its 2 skills, 2 commands.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for image-gen

README.md
[![agentmods](https://agentmods.dev/badge/skills/spillwavesolutions/image_gen/image-gen.svg)](https://agentmods.dev/skills/spillwavesolutions/image_gen/image-gen)
Your own site
<a href="https://agentmods.dev/skills/spillwavesolutions/image_gen/image-gen"><img src="https://agentmods.dev/badge/skills/spillwavesolutions/image_gen/image-gen.svg" alt="Measured on agentmods" height="20"></a>
Per session 61 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,543 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00061 $0.01543
Opus 5 $0.00030 $0.00772
Sonnet 5 $0.00012 $0.00309
Haiku 4.5 $0.00006 $0.00154

Measured 3d ago against content hash 3ac16fb9428f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

image-gen scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

The scan reads SKILL.md. This mod also ships 4 executable files (scripts/backends.py, scripts/generate.py, scripts/install_imagen.py, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/image-gen/SKILL.md · 167 lines

How it starts

The opening of the file, as written. The whole thing — 167 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Image Gen

Article image skill. Not the diagram renderer (that is imagen-diagrams).

When to fire

Use this skill when the user wants a cover image, in-article illustration, or visual assets for an article.

Do not use this skill to render Mermaid or PlantUML. Send those to imagen-diagrams.

Image-engine hint and backend (auto)

Use --engine-hint imagen, --engine-hint grok, or --engine-hint codex when the caller has a preferred image engine. The hint selects that engine only. It does not pretend every installed command has a standalone image subcommand.

  • Imagen: calls the imagen CLI directly.
  • Grok: calls grok-img, the noninteractive xAI image CLI. The plugin normalizes the generated image to the requested output path.
  • Codex: starts a Codex agent and asks it to use image_gen when that host exposes the tool.

Grok and Codex must write the requested PNG. A prose-only Codex result or a missing grok-img result fails closed and leaves the generated prompt sidecar for a manual retry. With no hint, auto tries each installed engine in order and falls through after a failed attempt, which lets an unauthenticated Imagen install reach another configured engine.

  1. imagen CLI if on PATH. Brace policy: imagen-cli-vars (double braces).
  2. Then grok-img CLI. Brace policy: grok-imagine (no rewrite).
  3. Else codex CLI. Brace policy: grok-imagine (no rewrite).
  4. Else fail closed. Write <stem>_imagen.prompt.txt and exit 2.

Never invent a PNG. If no worker is installed, keep the prompt sidecar and tell the user to run /image-gen-install.

Install the Grok image CLI

The --engine-hint grok adapter uses the noninteractive grok-img command, not Grok Build's interactive /imagine TUI. It needs Node.js 20.19 or newer and an xAI account with image-generation access.

npm install -g grok-image-cli
grok-img --version
grok-img auth login

Alternatively, configure the key noninteractively before running the skill:

Read the full file on GitHub · 167 lines

Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 167 lines · 61 tokens per session scan A 3ac16fb9428f

Subscribe to this mod's changes

image-gen is a skill published in the GitHub repository SpillwaveSolutions/image_gen (2 stars, last pushed 5d ago), licensed MIT. It adds 61 tokens to every session and 1,543 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

seo-image-gen

AI image generation for SEO assets: OG/social preview images, blog hero images, schema images, product photography, infographics. Powered by Gemini via nanobanana-mcp. Requires banana extension installed. Use when user says "generate image", "OG image", "social preview", "hero image", "blog image", "product photo"…

AgriciDaniel/claude-seo · 111 tokens

canvas

Create, inspect, and update Obsidian JSON Canvas boards with text, file, link, group, and edge nodes. Use for canvas status, canvas lists, visual maps, zones, spatial layouts, adding vault notes or media to a .canvas file, and requests such as create canvas, add to canvas, or put this on the canvas.

AgriciDaniel/claude-obsidian · 72 tokens

gpt-image

Use this skill whenever a user asks to generate, create, draw, render, or edit images with GPT Image 2 / gpt-image-2, text-to-image, reference-image editing, inpainting, posters, typography, Chinese text, UI mockups, diagrams, or gallery prompts. Analyze the user's prompt, search the bundled Reference Gallery/craft…

wuyoscar/GPT-Image2-Skill · 120 tokens

blog-chart

Generate dark-mode-compatible inline SVG data visualization charts for blog posts. Supports horizontal bar, grouped bar, donut, line, lollipop, area, and radar charts with automatic platform detection (HTML vs JSX/MDX). Enforces chart type diversity, accessible markup (role=img, aria-labelledby), source attribution…

AgriciDaniel/claude-blog · 164 tokens

asset-gen

Generate visual assets from text prompts: PNG images (Gemini / xAI Grok), GLB 3D models (Tripo3D), rigged biped characters, retargeted animations, and frame-by-frame animated sprites, plus background removal. Use whenever a game needs generated art.

htdt/godogen · 63 tokens

blog-image

AI image generation and editing for blog content powered by Gemini via MCP. Claude acts as Creative Director - interpreting intent, selecting domain expertise, constructing optimized 6-component prompts (Subject + Action + Context + Composition + Lighting + Style), and orchestrating Gemini for blog-quality results.…

AgriciDaniel/claude-blog · 176 tokens