Generate Image
Generate and edit images through OpenRouter's Image API, which reaches Gemini, Seedream, Recraft, GPT-Image, Riverflow, and roughly thirty other models behind one request shape.
When to use
Use this skill for: photos and photorealistic images, illustrations and artwork, concept art, presentation and poster visuals, logos and vector marks, image editing, and compositing from reference images.
Use scientific-schematics instead for: flowcharts, circuit diagrams, biological pathways,
system architecture diagrams, CONSORT diagrams, and other technical schematics.
API key
Generation requires an OpenRouter key. The script resolves it in this order:
--api-key- the
OPENROUTER_API_KEYenvironment variable OPENROUTER_API_KEY=in a.envfile, searching the working directory upward, then the script's own directory
If none is present the script exits with setup instructions. Keys: https://openrouter.ai/keys
--list-models, --model-info, and --dry-run need no key.
Quick start
# Generate
python scripts/generate_image.py "A beautiful sunset over mountains"
# Edit an existing image
python scripts/generate_image.py "Make …