Agent skill

Nano Banana

by glebis in glebis/claude-skills

Generate and edit images using Google's Gemini image generation models (Nano Banana family).

MITAuto-check passedMedia & Creative

Install Nano Banana

skills CLI
$ npx skills add glebis/claude-skills --skill nano-banana -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install glebis/claude-skills nano-banana --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/glebis/claude-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/nano-banana .claude/skills/nano-banana && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
nano-banana
GitHub stars
391
Token cost
~2.1k tokens
SKILL.md length
645 words
Files
8 (incl. scripts, references)
Skills in repo
92
Repo updated
First seen
Licence
MIT

At a glance

Generate and edit images using Google's Gemini image generation models (Nano Banana family).

  • Tasks that involve Image generation
  • SKILL.md covers When to Use, First-Time Setup, Quick Start and Requirements, plus 7 more sections
  • Runs Shell and Python scripts from its folder; calls python3 and magick; needs GEMINI_API_KEY
  • Tasks that involve Image editing

What it does

Nano Banana is an agent skill from glebis/claude-skills. Generate and edit images using Google's Gemini image generation models (Nano Banana family). Supports style presets, platform-specific sizing (YouTube/slides/blog), variants, image editing via inlineData, reference images for style transfer, and organized output with metadata. Default model is Nano Banana 2 (gemini-3.1-flash-image-preview). Key is auto-decrypted via SOPS.

Its SKILL.md is about 2.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 10 other files, including scripts and reference files (for example `.claude-plugin/plugin.json`, `platforms.yaml` and `presets.yaml`).

It sits in Media & Creative, covering Image generation and Image editing. It works with Google Gemini and YouTube. The repository describes itself as: Collection of Claude Code skills for enhanced AI workflows. The licence is MIT.

When your agent uses it

  • Tasks that involve Image generation
  • Tasks that involve Image editing

Example prompts

  • “/nano-banana”

Requirements

  • Python 3
  • A Bash shell
  • A credential in GEMINI_API_KEY

What it can do on your machine

Read from SKILL.md and the folder at commit 3b88261. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 2 files in scripts/ (Shell and Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python3
    • magick

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • GEMINI_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Nano Banana loads about 2.1k tokens when it runs, and up to ~2.8k if it reads all its reference files. Until then it costs about 97 tokens; SKILL.md has 645 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~97
When it runs · the whole SKILL.md, loaded when a task matches
~2.1k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~2.8k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from glebis/claude-skills at commit 3b88261, republished under its MIT licence (© glebis). 645 words, ~2,062 tokens.

Download SKILL.mdSave it as .claude/skills/nano-banana/SKILL.md (or your agent's skills folder). This skill also uses 7 other files; get the full folder from GitHub.
name
nano-banana
description
Generate and edit images using Google's Gemini image generation models (Nano Banana family). Supports style presets, platform-specific sizing (YouTube/slides/blog), variants, image editing via inlineData, reference images for style transfer, and organized output with metadata. Default model is Nano Banana 2 (gemini-3.1-flash-image-preview). Key is auto-decrypted via SOPS.

Nano Banana - Gemini Image Generation

Generate and edit images from text prompts via Google's Gemini image generation API.

When to Use

  • User requests image generation, creation, or production from a text description
  • Editing existing images with text instructions
  • Style-transfer: generate new images that match the aesthetic of a reference
  • Creating illustrations for presentations, articles, thumbnails, social posts
  • Batch variations of the same concept

First-Time Setup

bash
scripts/nano_banana.py init

Wizard checks dependencies (sops, age, magick), verifies the API key, and saves defaults to ~/.config/nano-banana/config.yaml.

Quick Start

bash
# Simple generation
scripts/nano_banana.py "a minimalist illustration of a rocket" ./rocket.png

# With style preset
scripts/nano_banana.py --preset editorial "interconnected nodes" ./nodes.png

# YouTube thumbnail (auto-cropped to 1280x720)
scripts/nano_banana.py --preset grain --platform youtube "coffee on desk" ./thumb.png

# Generate 4 variants + contact sheet
scripts/nano_banana.py --preset wireframe "a crystal" ./crystal.png --n 4

# Edit existing image
scripts/nano_banana.py --edit ./old.png "make the background deep teal" ./new.png

# Style reference (match aesthetic of existing image)
scripts/nano_banana.py --reference ./style.png "a new mountain landscape" ./mountain.png

# Re-roll last prompt
scripts/nano_banana.py again

# View history
scripts/nano_banana.py history -n 10

Requirements

  • GEMINI_API_KEY — auto-decrypted from secrets.enc.yaml via SOPS + age. Fallback: export GEMINI_API_KEY=...
  • sops, age — for key decryption
  • magick (ImageMagick) — for platform fit + contact sheets
  • python3 with pyyaml

Models

ModelAliasNano Banana NameUse When
gemini-3.1-flash-image-preview (default)flashNano Banana 2Best instruction following, fast
gemini-3-pro-image-previewproNano Banana ProHighest quality, text in images
gemini-2.5-flash-imageflash-2.5Nano Banana (original)Legacy

Use via --model flash|pro|flash-2.5 or full ID.

Style Presets

bash
scripts/nano_banana.py list-presets
scripts/nano_banana.py --preset editorial "your subject" out.png
PresetStyle
editorialThin lines on black, muted palette, technical diagram feel
blueprintWhite/cyan lines on dark navy, engineering drawing
inkJapanese sumi-e ink wash, organic brushstrokes, monochrome
risographFlat colors, grain, terracotta + sage, zine aesthetic
wireframe3D wireframe mesh, glowing edges on black
constellationStar map dots connected by faint lines, celestial
brutalistBold shapes, thick borders, hard shadows, flat colors
grainFilm grain photo, high ISO, warm cinematic tones

Defined in presets.yaml — edit to add your own.

Platform Presets

bash
scripts/nano_banana.py list-platforms
scripts/nano_banana.py --platform youtube "your subject" out.png

Generated image is automatically resized + center-cropped to target dimensions.

PlatformSize
youtube1280×720
youtube-short1080×1920
slides1920×1080
blog1200×630
x1600×900
square1080×1080
story1080×1920
pinterest1000×1500

Features

Variants + Contact Sheet

--n N generates N variants in parallel and assembles them into a contact sheet:

bash
scripts/nano_banana.py --preset ink "mountain" ./mt.png --n 6
# Creates mt-01.png ... mt-06.png + mt-contact.png
Batch generation (campaigns / multi-copy ad sets)

When each output needs different text or a different prompt (e.g. a set of ads sharing one style), loop over a list. --n won't help here — it re-rolls the same prompt. Use a shared $STYLE string + a per-item array.

bash
cd /abs/output/dir
REF="_reference.png"   # optional style anchor
STYLE="<shared visual-style description, written once>"

# Each entry: pipe-delimited fields + output filename. NAME the array — see gotchas.
ADS=(
"CALL NOW|FOR TOTAL|CONFIDENTIALITY|ad-callnow.png"
"REDACT|BEFORE|YOU SEND|ad-redact.png"
)
for entry in "${ADS[@]}"; do
  IFS='|' read -r L1 L2 L3 OUT <<< "$entry"
  python3 scripts/nano_banana.py \
    "$STYLE The exact text reads, on three centered lines: '$L1' / '$L2' / '$L3'. Spell every word correctly." \
    "$OUT" --reference "$REF" --platform youtube --model pro --no-metadata --project NAME
done

Shell gotchas (this is zsh on macOS — these bite every time):

  • Never name a loop array LINES, COLUMNS, PATH, path, status, argv, etc. — zsh reserves them. LINES=(...) fails with can't assign array value to non-array special. Use ADS, ITEMS, JOBS.
  • zsh does NOT word-split unquoted variables (unlike bash). CMD="magick montage"; $CMD ... looks for a single command literally named "magick montage". Don't stuff multi-word commands in a var — call the command directly, or use an array (cmd=(magick montage); "${cmd[@]}").
  • Always quote expansions — "$OUT", "${ADS[@]}" — paths and prompts contain spaces.
  • Use 'single quotes' for the exact text you want rendered, inside the double-quoted prompt, so the model reproduces it verbatim.
  • To parallelize a batch, append & per iteration and wait at the end — but cap concurrency (the API rate-limits); sequential is safest for >6 items.

After a batch, assemble a review sheet by calling the tool directly (no var indirection): magick montage ad-*.png -tile 2x3 -geometry 480x270+6+6 -background black _contact.png.

Show full SKILL.md (166 more words)Show less
Edit Mode

Pass an existing image and the prompt becomes the edit instruction:

bash
scripts/nano_banana.py --edit ./thumb.png "remove the watermark, warmer colors" ./clean.png
Reference Images (Style Anchor)

Use one or more reference images to guide the aesthetic without editing them:

bash
scripts/nano_banana.py --reference ./episode1.png --reference ./episode2.png \
  "episode 3: data drift" ./ep3.png
Projects + Metadata

Organize outputs by project:

bash
scripts/nano_banana.py --project lab-04/meeting-02 --preset editorial "MCP loops" ./overlay.png
# Saves to ~/nano-banana/outputs/lab-04/meeting-02/20260414-<subject>.png + .json sidecar
Re-roll + History
bash
scripts/nano_banana.py again              # rerun last prompt
scripts/nano_banana.py history -n 20      # show last 20 generations
scripts/nano_banana.py history --project lab-04
Dry Run

Preview the composed prompt without calling the API:

bash
scripts/nano_banana.py --preset editorial --platform youtube "subject" --dry-run

Transient Errors & Retry

The API occasionally returns 500/INTERNAL or empty candidates. The script retries up to 4 times with exponential backoff (2s, 4s, 8s, 16s). Permanent errors (4xx, safety violations) fail fast without retry.

Prompt Tips

  • Specify visual style: "photograph", "flat illustration", "watercolor", "3D render"
  • Include composition: "centered", "white background", "wide shot"
  • Name colors: "blue and white color scheme", "warm earth tones"
  • For text rendering, use --model pro and quote exact text: 'with the text "Hello"'

See references/api_reference.md for full API documentation.

Files

  • scripts/nano_banana.py — main CLI (Python)
  • scripts/generate_image.sh — thin bash wrapper (back-compat)
  • presets.yaml — style presets
  • platforms.yaml — platform sizing presets
  • secrets.enc.yaml — encrypted API key (SOPS + age)
  • ~/.config/nano-banana/config.yaml — user defaults (from init)
  • ~/.config/nano-banana/history.jsonl — generation log
  • ~/.config/nano-banana/last.json — last run (for again)

© glebis, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 7 other files (scripts, references) in nano-banana of glebis/claude-skills.

  • SKILL.md
  • .claude-plugin/plugin.json
  • platforms.yaml
  • presets.yaml
  • references/api_reference.md
  • scripts/generate_image.sh
  • scripts/nano_banana.py
  • secrets.enc.yaml

Open the folder on GitHubat commit 3b88261

Compare with similar skills

Nano Banana next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Nano Banana compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Nano Banana this skillglebis/claude-skills391—~2.1kAutomated safety check: PassMIT
Nano Bananajh941213/my-cc-harness125—~1kAutomated safety check: PassNone
AI Image Generation and Editingzhayujie/CowAgent47k—~1.3kAutomated safety check: PassMIT
BlockRun Image GenerationBlockRunAI/ClawRouter6.6k—~2.1kAutomated safety check: PassMIT
Antigravity Gemini ImageuluckyXH/OpenMOSS1.3k—~730Automated safety check: NotesMIT
Nano Bananakkoppenhaver/cc-nano-banana3781 repos~1.4kAutomated safety check: PassMIT

Similar skills

  • Nano Banana

    jh941213/my-cc-harness

    REQUIRED for all image generation requests. An agent skill from jh941213/my-cc-harness.

    125 GitHub stars~1k tokensUpdated 2 mo ago
    Media & CreativeAuto-check passed
  • Generates or edits images from text prompts through a Python script that picks an image backend based on which API keys are configured.

    47k GitHub stars~1.3k tokensUpdated yesterday
    Media & CreativeAuto-check passed
  • BlockRun Image Generation

    BlockRunAI/ClawRouter

    Generates or edits images through ClawRouter's local image API, with a choice of models and sizes and payment handled automatically through x402.

    6.6k GitHub stars~2.1k tokensUpdated 6 days ago
    Media & CreativeAuto-check passed
  • Antigravity Gemini Image

    uluckyXH/OpenMOSS

    Generate or edit images using the Antigravity-hosted Gemini image model via the local gateway.

    1.3k GitHub stars~730 tokensUpdated 3 mo ago
    Media & CreativeAuto-check: notes
  • Nano Banana

    kkoppenhaver/cc-nano-banana

    REQUIRED for all image generation requests. An agent skill from kkoppenhaver/cc-nano-banana.

    378 GitHub starsUsed in 1 repo~1.4k tokens
    Media & CreativeAuto-check passed
  • Figure

    Muuuun/luxas

    Hybrid figure pipeline (Nano Banana raster + rembg background removal + TikZ vector assembly).

    1.2k GitHub stars~1.2k tokensUpdated 1 mo ago
    Media & CreativeAuto-check passed

More from glebis/claude-skills

All 92 skills in this repo
  • Runs a human-first workflow for labeling PII spans in a transcript, then scores inter-annotator agreement and drafts an adjudicated gold set.

    391 GitHub stars~1.3k tokensUpdated 3 days ago
    Auto-check passed
  • Automates a dedicated, logged-in Chrome instance per profile without ever closing the user's own open tabs or browser windows.

    391 GitHub stars~973 tokensUpdated 3 days ago
    Auto-check passed
  • Deep Research

    glebis/claude-skills

    This skill should be used when conducting comprehensive research on any topic using the OpenAI Deep Research API.

    391 GitHub stars~2.6k tokensUpdated 3 days ago
    Auto-check: notes
  • Elimination Research

    glebis/claude-skills

    This skill should be used for elimination-style research where the user wants to choose from a shortlist of products, tools, services, vendors, or other options using explicit criteria, numeric…

    391 GitHub stars~1.6k tokensUpdated 3 days ago
    Auto-check passed
  • Narrated HTML Presentations

    glebis/claude-skills

    Generates a self-contained HTML presentation with article and slides modes, ElevenLabs voiceover narration and optional GPT Image 2 illustrations.

    391 GitHub stars~2.3k tokensUpdated 3 days ago
    Auto-check: notes
  • Writes fictional but realistic coaching or therapy session transcripts for evals, demos and few-shot examples, in several modalities and export formats.

    391 GitHub stars~2.9k tokensUpdated 3 days ago
    Auto-check passed

Questions about Nano Banana

What does Nano Banana do?

Generate and edit images using Google's Gemini image generation models (Nano Banana family). Nano Banana is an agent skill from glebis/claude-skills. Generate and edit images using Google's Gemini image generation models (Nano Banana family).

When should I use Nano Banana?

Nano Banana fits situations like: tasks that involve Image generation; tasks that involve Image editing.

How do I install Nano Banana in Claude Code?

Run `npx skills add glebis/claude-skills --skill nano-banana -a claude-code`. Or copy the skill folder (nano-banana in glebis/claude-skills) into .claude/skills/nano-banana in your project. Claude Code loads it when a task matches its description.

How do I install Nano Banana in Codex?

Run `npx skills add glebis/claude-skills --skill nano-banana -a codex`. Or copy the skill folder (nano-banana in glebis/claude-skills) into .agents/skills/nano-banana in your project. Codex loads it when a task matches its description.

Can I use Nano Banana in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add glebis/claude-skills --skill nano-banana -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/nano-banana, .gemini/skills/nano-banana, .github/skills/nano-banana and .opencode/skills/nano-banana in your project.

What does Nano Banana need to run?

Going by SKILL.md and its folder, Nano Banana needs a shell and Python for the scripts in its folder, the command-line tools its instructions call (python3 and magick) and credentials named GEMINI_API_KEY. Our summary lists: Python 3; A Bash shell; A credential in GEMINI_API_KEY.

Does Nano Banana access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Nano Banana safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Nano Banana use?

Nano Banana is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Nano Banana use?

About 2.1k tokens (SKILL.md is roughly 8.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 762 tokens, read only when the agent opens those files.

What are the alternatives to Nano Banana?

Skills that share tags, products or a category with Nano Banana: Nano Banana (jh941213/my-cc-harness, 125 stars), AI Image Generation and Editing (zhayujie/CowAgent, 47k stars), BlockRun Image Generation (BlockRunAI/ClawRouter, 6.6k stars) and Antigravity Gemini Image (uluckyXH/OpenMOSS, 1.3k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Nano Banana?

glebis (a GitHub user) maintains it in glebis/claude-skills, which has 391 GitHub stars. The repository holds 92 skills in this directory. The repository was last updated on October 8, 2026.

Source: glebis/claude-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.