All skills
github avatar

/nano-banana-pro-openrouter

@b087965 official
by githubgithub/awesome-copilot40k stars
5,040

Generate or edit images via OpenRouter with the Gemini 3 Pro Image model. Use for prompt-only image generation, image edits, and multi-image compositing; supports 1K/2K/4K output.

Use this Skill: https://skilld.dev/gh/github/awesome-copilot/nano-banana-pro-openrouter

This session only. Nothing lands on disk.

SKILL.md

≈52 tokens always: the name and description. ≈574 when used: this file.

Nano Banana Pro OpenRouter

Overview

Generate or edit images with OpenRouter using the google/gemini-3-pro-image-preview model. Support prompt-only generation, single-image edits, and multi-image composition.

Prompt-only generation

uv run {baseDir}/scripts/generate_image.py \
  --prompt "A cinematic sunset over snow-capped mountains" \
  --filename sunset.png

Edit a single image

uv run {baseDir}/scripts/generate_image.py \
  --prompt "Replace the sky with a dramatic aurora" \
  --input-image input.jpg \
  --filename aurora.png

Compose multiple images

uv run {baseDir}/scripts/generate_image.py \
  --prompt "Combine the subjects into a single studio portrait" \
  --input-image face1.jpg \
  --input-image face2.jpg \
  --filename composite.png

Resolution

  • Use --resolution with 1K, 2K, or 4K.
  • Default is 1K if not specified.

System prompt customization

The skill reads an optional system prompt from assets/SYSTEM_TEMPLATE. This allows you to customize the image generation behavior without modifying code.

Behavior and constraints

  • Accept up to 3 input images via repeated --input-image.
  • --filename accepts relative paths (saves to current directory) or absolute paths.
  • If multiple images are returned, append -1, -2, etc. to the filename.
  • Print MEDIA: <path> for each saved image. Do not read images back into the response.

Troubleshooting

If the script exits non-zero, check stderr against these common blockers:

Symptom Resolution
OPENROUTER_API_KEY is not set Ask the user to set it. PowerShell: $env:OPENROUTER_API_KEY = "sk-or-..." / bash: export OPENROUTER_API_KEY="sk-or-..."
uv: command not found or not recognized macOS/Linux: <code>curl -LsSf https://astral.sh/uv/install.sh &#124; sh</code>. Windows: <code>powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 &#124; iex"</code>. Then restart the terminal.
AuthenticationError / HTTP 401 Key is invalid or has no credits. Verify at https://openrouter.ai/settings/keys.

For transient errors (HTTP 429, network timeouts), retry once after 30 seconds. Do not retry the same error more than twice — surface the issue to the user instead.

Source: SKILL.md on GitHub

1 warning16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    The skill is safe. It allows users to generate, edit, or composite images using the Gemini 3 Pro Image model via the OpenRouter API. Dependencies and API integrations follow standard development practices.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: LOW · No issues

  • Runlayer7mo

    3/3 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at b087965. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 20 hours ago.

Activeupdated 8 months ago
Other metadata
metadata
{
  "emoji": "🍌",
  "requires": {
    "bins": [
      "uv"
    ],
    "env": [
      "OPENROUTER_API_KEY"
    ]
  },
  "primaryEnv": "OPENROUTER_API_KEY"
}
  • API
  • image-generation
  • image-editing
  • openrouter
  • gemini
  • generative-ai
  • composition
  • uv

README badge

README badge for github/awesome-copilot/nano-banana-pro-openrouter

Generates or edits images via OpenRouter using the Gemini 3 Pro Image model, supporting prompt-only generation, single-image edits, and multi-image composition at 1K/2K/4K resolutions. Requires an OpenRouter API key and the uv package manager.

Generated from the current SKILL.md.

What image generation model does this skill use?
The skill uses the google/gemini-3-pro-image-preview model via OpenRouter. It supports prompt-only generation, single-image edits, and multi-image composition up to 3 images.
What output resolutions are supported?
The skill supports 1K, 2K, and 4K output resolutions via the --resolution flag. If not specified, it defaults to 1K.
Do I need to set up an API key?
Yes. You must set the OPENROUTER_API_KEY environment variable with a valid OpenRouter API key before running the skill.
Can I customize the image generation behavior?
Yes. The skill reads an optional system prompt from assets/SYSTEM_TEMPLATE to customize behavior without modifying code.
What should I do if I get an AuthenticationError?
Your API key is invalid or has no credits. Verify your key at https://openrouter.ai/settings/keys and ensure it has available balance.

Generated from the current SKILL.md. These answers refresh after source changes.