generate-image
Skill4 starsChanged 5 months agoMITView on GitHub
Generate or edit images using AI models (FLUX, Nano Banana 2). Use for general-purpose image generation including photos, illustrations, artwork, visual assets, concept art, and any image that is not a technical diagram or schematic. For flowcharts, circuits, pathways, and technical diagrams, use the scientific-schematics skill instead.
- Reads credentials
37 other projects use a version of this, 9 of them edited.
Adopted by
Most recently taken up by
- lancy69/skillstheir own version, first seen Nov 8, 2026
- oivanfelipe/claude-skillstheir own version, first seen Nov 8, 2026
- BrightGold70/skillsedited, first seen Nov 8, 2026
- K-Dense-AI/claude-scientific-writertheir own version, first seen Nov 7, 2026
- the-gigi/learn-claude-codetheir own version, first seen Nov 1, 2026
- MakiDevelop/claude-skillstheir own version, first seen Nov 1, 2026
Used with
Projects with it also use edit-image, team and 2 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
SamurAIGPTSkilledit-image
Edits an existing image using natural language instructions via MuAPI. Use when the user wants to modify, change, transform, or retouch an existing image.
Also in 3 projects that use this
nicepkgSkillteam
根据任务快速组建临时 AI Agent 团队协作。自动从 .claude/agents/ 中选择最合适的成员组队。
Also in 3 projects that use this
AnthropicSkillpdf
Comprehensive PDF manipulation toolkit for extracting text and tables, creating new PDFs, merging/splitting documents, and handling forms. When Claude needs to fill in a PDF form or programmatically process, generate, or analyze PDF documents at scale.
Also in 4 projects that use this
AnthropicSkillxlsx
Comprehensive spreadsheet creation, editing, and analysis with support for formulas, formatting, data analysis, and visualization. When Claude needs to work with spreadsheets (.xlsx, .xlsm, .csv, .tsv, etc) for: (1) Creating new spreadsheets with formulas and formatting, (2) Reading or analyzing data, (3) Modify existing spreadsheets while preserving formulas, (4) Data analysis and visualization in spreadsheets, or (5) Recalculating formulas
Also in 3 projects that use this
Other versions37 projects use a version of this.
Word for word · 0
None found.
Edited · 9
- LeonChaoX/qinyan-academic-skills★ 910100% same
- qinyan-ai/qinyan-academic-skills★ 80100% same
- hxhx-win/zhuanli-flow★ 499% same
- MarieLynneBlock/arcanum-artifex★ 499% same
- Oceanjackson1/Claude-Skill★ 2100% same
- BrightGold70/skills★ 185% same
- garri333/Skills★ 185% same
- uppifyagency/boilerplate-saas-2026★ 1100% same
- yf8578/claude-skills-collection★ 188% same
Wrote their own version · 28
- github/awesome-copilot★ 41ksame name
- K-Dense-AI/claude-scientific-writer★ 2.6ksame name
- OpenClaudia/openclaudia-skills★ 731same name
- ansari-project/codev★ 298same name
- cluesmith/codev★ 298same name
- Sateezg/codex-bridge★ 248same name
- DojoCodingLabs/remotion-superpowers★ 153same name
- happycapy-ai/Happycapy-skills★ 137same name
- maxedapps/agent-skills★ 59same name
- ApurvaMisra/claude-code-assistant★ 8same name
18 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository40 other files it gives its agents.
- academic-paper-reviewerSkill
- academic-paperSkill
- academic-pipelineSkill
- brandkitSkill
- industrial-brutalist-uiSkill
- chinese-novelistSkill
- claude-verifierSkill
- deep-researchSkill
- find-skillsSkill
- gpt-tasteSkill
- imagegen-frontend-mobileSkill
- imagegen-frontend-webSkill
- image-to-codeSkill
- infographicsSkill
- md-to-pptxSkill
- minimalist-uiSkill
- n8n-code-javascriptSkill
- n8n-code-pythonSkill
- n8n-expression-syntaxSkill
- n8n-mcp-tools-expertSkill
- n8n-node-configurationSkill
- n8n-validation-expertSkill
- n8n-workflow-patternsSkill
- full-output-enforcementSkill
- page-agentSkill
- pptx-postersSkill
- pptxSkill
- redesign-existing-projectsSkill
- remotion-best-practicesSkill
- scientific-slidesSkill
- skill-creatorSkill
- skill-evolutionSkill
- skill-factorySkill
- skill-lookupSkill
- skill-managerSkill
- skill-writerSkill
- high-end-visual-designSkill
- stitch-design-tasteSkill
- design-taste-frontendSkill
- design-taste-frontend-v1Skill
The file
Show its rules and text
We split this skill into the rules it gives an agent
14 rules. 0 are common, 10 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 31 edited versions we read keep these.
10
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 37
Use the scripts/generate_image.py script to generate or edit images:
- Very specific: line 53
Look for a .env file in the project directory or parent directories
- Very specific: line 54
Check for OPENROUTER_API_KEY=<key> in the .env file
- Distinctive: line 55
If not found, inform the user they need to:
- Very specific: line 56
Create a .env file with OPENROUTER_API_KEY=your-api-key-here
- Distinctive: line 74
Quality: Use gemini-3.1-flash-image-preview or flux.2-pro
- Distinctive: line 75
Editing: Use gemini-3.1-flash-image-preview or flux.2-pro (both support image editing)
- Distinctive: line 76
Cost: Use flux.2-flex for generation only
- Distinctive: line 111
Run the script multiple times with different prompts or output paths:
- Distinctive: line 162
If the script fails, read the error message and address the issue before retrying.
- Distinctive: line 171
Check OpenRouter pricing for cost information: https://openrouter.ai/models
- Distinctive: line 182
scientific-schematics: Use for technical diagrams, flowcharts, circuits, pathways
- Distinctive: line 183
generate-image: Use for photos, illustrations, artwork, visual concepts
- Distinctive: line 185
latex-posters: Use generate-image for poster visuals and hero images
“Common” is measured: kept by at least 6 in 10 of the 31 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Generate Image
Generate and edit high-quality images using OpenRouter's image generation models including FLUX.2 Pro and Gemini 3.1 Flash Image Preview.
When to Use This Skill
Use generate-image for:
- Photos and photorealistic images
- Artistic illustrations and artwork
- Concept art and visual concepts
- Visual assets for presentations or documents
- Image editing and modifications
- Any general-purpose image generation needs
Use scientific-schematics instead for:
- Flowcharts and process diagrams
- Circuit diagrams and electrical schematics
- Biological pathways and signaling cascades
- System architecture diagrams
- CONSORT diagrams and methodology flowcharts
- Any technical/schematic diagrams
Quick Start
Use the scripts/generate_image.py script to generate or edit images:
# Generate a new image
python scripts/generate_image.py "A beautiful sunset over mountains"
# Edit an existing image
python scripts/generate_image.py "Make the sky purple" --input photo.jpgThis generates/edits an image and saves it as generated_image.png in the current directory.
API Key Setup
CRITICAL: The script requires an OpenRouter API key. Before running, check if the user has configured their API key:
- Look for a
.envfile in the project directory or parent directories - Check for
OPENROUTER_API_KEY=<key>in the.envfile - If not found, inform the user they need to:
- Create a
.envfile withOPENROUTER_API_KEY=your-api-key-here - Or set the environment variable:
export OPENROUTER_API_KEY=your-api-key-here - Get an API key from: https://openrouter.ai/keys
- Create a
The script will automatically detect the .env file and provide clear error messages if the API key is missing.
Model Selection
Default model: google/gemini-3.1-flash-image-preview (high quality, recommended)
Available models for generation and editing:
google/gemini-3.1-flash-image-preview- High quality, supports generation + editingblack-forest-labs/flux.2-pro- Fast, high quality, supports generation + editing
Generation only:
black-forest-labs/flux.2-flex- Fast and cheap, but not as high quality as pro
Select based on:
- Quality: Use gemini-3.1-flash-image-preview or flux.2-pro
- Editing: Use gemini-3.1-flash-image-preview or flux.2-pro (both support image editing)
- Cost: Use flux.2-flex for generation only
Common Usage Patterns
Basic generation
python scripts/generate_image.py "Your prompt here"Specify model
python scripts/generate_image.py "A cat in space" --model "black-forest-labs/flux.2-pro"Custom output path
python scripts/generate_image.py "Abstract art" --output artwork.pngEdit an existing image
python scripts/generate_image.py "Make the background blue" --input photo.jpgEdit with a specific model
python scripts/generate_image.py "Add sunglasses to the person" --input portrait.png --model "black-forest-labs/flux.2-pro"Edit with custom output
python scripts/generate_image.py "Remove the text from the image" --input screenshot.png --output cleaned.pngMultiple images
Run the script multiple times with different prompts or output paths:
python scripts/generate_image.py "Image 1 description" --output image1.png
python scripts/generate_image.py "Image 2 description" --output image2.pngScript Parameters
prompt(required): Text description of the image to generate, or editing instructions--inputor-i: Input image path for editing (enables edit mode)--modelor-m: OpenRouter model ID (default: google/gemini-3.1-flash-image-preview)--outputor-o: Output file path (default: generated_image.png)--api-key: OpenRouter API key (overrides .env file)
Example Use Cases
For Scientific Documents
# Generate a conceptual illustration for a paper
python scripts/generate_image.py "Microscopic view of cancer cells being attacked by immunotherapy agents, scientific illustration style" --output figures/immunotherapy_concept.png
# Create a visual for a presentation
python scripts/generate_image.py "DNA double helix structure with highlighted mutation site, modern scientific visualization" --output slides/dna_mutation.pngFor Presentations and Posters
# Title slide background
python scripts/generate_image.py "Abstract blue and white background with subtle molecular patterns, professional presentation style" --output slides/background.png
# Poster hero image
python scripts/generate_image.py "Laboratory setting with modern equipment, photorealistic, well-lit" --output poster/hero.pngFor General Visual Content
# Website or documentation images
python scripts/generate_image.py "Professional team collaboration around a digital whiteboard, modern office" --output docs/team_collaboration.png
# Marketing materials
python scripts/generate_image.py "Futuristic AI brain concept with glowing neural networks" --output marketing/ai_concept.pngError Handling
The script provides clear error messages for:
- Missing API key (with setup instructions)
- API errors (with status codes)
- Unexpected response formats
- Missing dependencies (requests library)
If the script fails, read the error message and address the issue before retrying.
Notes
- Images are returned as base64-encoded data URLs and automatically saved as PNG files
- The script supports both
imagesandcontentresponse formats from different OpenRouter models - Generation time varies by model (typically 5-30 seconds)
- For image editing, the input image is encoded as base64 and sent to the model
- Supported input image formats: PNG, JPEG, GIF, WebP
- Check OpenRouter pricing for cost information: https://openrouter.ai/models
Image Editing Tips
- Be specific about what changes you want (e.g., "change the sky to sunset colors" vs "edit the sky")
- Reference specific elements in the image when possible
- For best results, use clear and detailed editing instructions
- Both Gemini 3.1 Flash Image Preview and FLUX.2 Pro support image editing through OpenRouter
Integration with Other Skills
- scientific-schematics: Use for technical diagrams, flowcharts, circuits, pathways
- generate-image: Use for photos, illustrations, artwork, visual concepts
- scientific-slides: Combine with generate-image for visually rich presentations
- latex-posters: Use generate-image for poster visuals and hero images
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

