openrouter-text2image
Generate images via OpenRouter. Default model openai/gpt-5.4-image-2; any image-modality model can be passed via --model.
npx skills add QinghongLin/data2story-skill --skill openrouter-text2image --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# openrouter-text2image Text → image via OpenRouter. Default model: `openai/gpt-5.4-image-2`. Other supported models (override with `--model`): - `google/gemini-3.1-flash-image-preview` (Nano Banana 2) - any other OpenRouter image-modality model ## Usage Resolve `TOOL_DIR` = the directory containing this `SKILL.md`. Commands below use `TOOL_DIR` as a symbolic placeholder; replace it with the resolved, quoted path before running Bash. ```bash export OPENROUTER_API_KEY=sk-or-v1-... python3 TOOL_DIR/scripts/generate_image.py \ --prompt "Editorial illustration: a neon-lit skateboard at dusk, dramatic shadows" \ --download PROJECT_DIR/assets/teaser.png ``` ## Flags | Flag | Default | Description | |---|---|---| | `--prompt` | required | Text prompt | | `--download` | required | Output file path (PNG) | | `--model` | `openai/gpt-5.4-image-2` | Override with any OpenRouter image-modality model | ## Notes - Request uses `POST /api/v1/chat/completions` with `modalities: ["image","text"]`. - Images are returned as base64 data URLs in the assistant message; the script decodes and writes to disk. - For edits/inpainting, include `messages` with both text and image-URL content parts — the script
- Usage
- Flags
- Notes
export OPENROUTER_API_KEY=sk-or-v1-... python3 TOOL_DIR/scripts/generate_image.py \
What does the openrouter-text2image skill do?
Generate images via OpenRouter. Default model openai/gpt-5.4-image-2; any image-modality model can be passed via --model.
How do I install it?
Run `npx skills add QinghongLin/data2story-skill --skill openrouter-text2image --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From QinghongLin/data2story-skill, a repository with 149 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
