imgen

imgen is a skill for Claude Code, Codex from walker1211/codex-imgen. It costs 73 tokens per session (867 once invoked), scanned A, original, MIT.

An image-generation workflow for the codex-imgen tool and its service jobs. It covers creating or editing raster images, meaning ordinary pixel-based images, plus troubleshooting and delivery through OpenClaw.

In plain words
What is it for?
It is for text-to-image and image-to-image work, checking or cancelling jobs, diagnosing failures, and sending generated images through OpenClaw.
Why use it?
It helps choose the right image workflow and gives the shortest applicable command without asking for unnecessary preferences.

Skill for Claude CodeCodex

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/walker1211/codex-imgen/imgen
Any agent
npx skills add walker1211/codex-imgen --skill imgen
Clone the repo
git clone --depth 1 https://github.com/walker1211/codex-imgen

Made for: Claude Code, Codex.

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 imgen

README.md
[![agentmods](https://agentmods.dev/badge/skills/walker1211/codex-imgen/imgen.svg)](https://agentmods.dev/skills/walker1211/codex-imgen/imgen)
Your own site
<a href="https://agentmods.dev/skills/walker1211/codex-imgen/imgen"><img src="https://agentmods.dev/badge/skills/walker1211/codex-imgen/imgen.svg" alt="Measured on agentmods" height="20"></a>
Per session 73 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 867 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.00073 $0.00867
Opus 5 $0.00036 $0.00434
Sonnet 5 $0.00015 $0.00173
Haiku 4.5 $0.00007 $0.00087

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

Security

Grade A, and why

imgen 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.

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.

.agents/skills/imgen/SKILL.md · 79 lines

How it starts

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

imgen

Use this skill to operate the codex-imgen CLI, service jobs, realtime mode, and OpenClaw integration.

Route the request

Read only the references needed for the request:

  • references/imgen-usage.md: commands, configuration, backend behavior, service/realtime selection, and the OpenClaw delivery contract.
  • references/prompt-patterns.md: prompt wording for text-to-image or image-to-image requests.
  • references/troubleshooting.md: failed, slow, retried, stuck, or missing-image runs.

Combine references only when the request spans those concerns.

Ask only necessary questions

If the user gave enough information, provide the command or steps directly.

Ask one question only when a required value is missing:

  • Missing image prompt for generation.
  • Missing local image path for image-to-image.
  • Missing job id for status, get, cancel, or job-specific troubleshooting.
  • Missing choice between synchronous CLI, service job, or realtime only when the goal does not determine it.

Do not ask for preferences that are not needed to produce a safe minimal command.

Command rules

  • Use the shortest command that satisfies the request.
  • Default one-shot generation, including normal OpenClaw requests, to synchronous ./imgen --json ... from a discovered config working directory.
  • Use repeated --image <local-path> flags for references; URLs are not supported.
  • Use --count N and --concurrency M for quantity while keeping the prompt about one image.
  • Use submit only for job management, polling, cancellation, or recovery. Use realtime only for live WebSocket events while imgen serve is running.
  • Treat success as returned image paths: text path lines, or ok: true with non-empty images[].path. Exit code 0 alone is insufficient.
  • For OpenClaw, follow the full contract in references/imgen-usage.md; never substitute image_generate, direct codex exec, or stale paths.

Safety and configuration rules

  • Treat .env as the only place for sensitive values such as EMAIL_SMTP_AUTH_CODE.
  • Treat configs/config.yaml as the local structured configuration file.
  • Do not suggest committing configs/config.yaml, .env, generated images, logs, or .data/imgen.db.
  • Do not suggest 0.0.0.0 service binding unless the user explicitly asks for LAN access and understands the exposure.
  • Do not bypass Codex CLI login, permissions, or $imagegen availability checks.
  • Inspect backend.model and backend.reasoning_effort before describing the active Codex agent configuration. The skill itself does not choose either value.
  • Do not call backend.model the image-generation model; it selects the Codex agent that invokes $imagegen.

Read the full file on GitHub · 79 lines

Files

What ships with it

4 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 · 79 lines · 73 tokens per session scan A 3ed846158f62

Subscribe to this mod's changes

imgen is a skill published in the GitHub repository walker1211/codex-imgen (2 stars, last pushed 1mo ago), licensed MIT. It adds 73 tokens to every session and 867 once invoked, about $0.0004 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

mobilevc-installer

Install and start MobileVC — a Claude Code mobile workspace launcher that lets the user run Claude Code on a phone (iOS / Android) with their dev machine as the backend. Use this skill when the user asks to: "install mobilevc" / "set up mobilevc" / "装一个 mobilevc" "在手机上用 Claude Code" / "want to use Claude Code on my…

JayCRL/MobileVC · 222 tokens

sprite-atlas-builder

Sprite atlas pipeline. Use for sprites, tilesets, textures, asset sheets, extraction, curation, and QA.

gvastethecreator/codex-studio · 29 tokens

codex-studio-setup

Set up a local Codex Studio checkout end to end from the welcome-screen handoff prompt.

gvastethecreator/codex-studio · 26 tokens

add

Turn a plain-language guardrail into a handrail Rule file, validate it, and relay the native permission entry handrail recommends. Use when the user wants to add, write, or create a handrail rule, or says "never let the agent ...", "block ...", "warn me when ..." and wants it enforced from now on.

svyatov/handrail · 71 tokens

analyze

Mine the current session for behaviors worth preventing and propose handrail Rules for them, with transcript evidence and per-rule approval. Use when the user wants to turn this session's corrections into guardrails, or says "analyze this session", "what should I have blocked", "make that a rule so it never happens…

svyatov/handrail · 68 tokens

codexcw

Run Codex, Claude Code, or Grok Build non-interactively from Go, Rust, Node.js, Python, or C# using the codexcw library. Use when building automation that spawns an agent, streams its JSONL events, resumes sessions, or controls sandbox, approval, and permission policy.

c3-oss/codexcw · 67 tokens