Token导航 LogoToken导航

Agent Skill · 前端设计

nano-banana-pro(纳米香蕉专业版)

nano-banana-pro 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

nano-banana-pro 是前端设计类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证为 MIT,第三方扫描已通过,按安装量在前端设计类的 10,216 个 Skill 里排第 2,696。

总安装 1,983周安装 81GitHub Stars 7下载 635核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:nano-banana-pro(纳米香蕉专业版)
来源仓库:https://github.com/enzed/skills
仓库路径:skills/nano-banana-pro
安装命令:
npx skills add https://github.com/enzed/skills --skill nano-banana-pro
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/enzed/skills --skill nano-banana-pro

这个 Skill 是做什么的

前端设计类 Skill 关注页面结构、视觉规范和组件写法,输出通常是可运行的界面代码。

nano-banana-pro 利用 Google Gemini 3 Pro 模型生成带透明通道的游戏素材与图标,支持高级编辑。适用于 Codex、Claude、Cursor、Gemini CLI 中需要快速产出 PNG 贴纸、UI 元素或概念图的创意场景。

必须通过 scripts/generate.py CLI 调用,API 密钥从 .env 读取,不支持直接编写 Python 脚本。生成结果仅供参考,版权归属原作者,商业用途前应确认模型许可协议与署名要求,避免侵权风险。

适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

来源仓库内路径:skills/nano-banana-pro

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/enzed/skills --skill nano-banana-pro;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

nano-banana-pro 怎么安装?

在终端执行 npx skills add https://github.com/enzed/skills --skill nano-banana-pro。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

nano-banana-pro 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

nano-banana-pro 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

nano-banana-pro 是免费的吗?

来源标注的许可证是 MIT。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

nano-banana-pro 用的人多吗?

公开数据是累计安装 1,983 次,近一周安装 81 次,下载 635 次,GitHub 7 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

nano-banana-pro 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 3 个目录同时收录,说明这个 Skill 流传比较广。
  • 许可证明确为 MIT,商用和分发边界好判断。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理前端设计类任务、又不想每次都手写提示词的人。
  • 需要许可证清楚、并且有第三方扫描结果的团队项目。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要厂商级技术支持和 SLA 的生产系统。

前端设计类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
frontend-design

前端设计 · Codex、Claude

8,823,360126,072只读MIT通过
vercel-composition-patterns

Vercel 组合模式 · Codex、Claude

3,858,81625,893需要联网MIT通过
vercel-react-native-skills

Vercel React native skills 前端 · Codex、Claude

2,468,66425,878只读MIT通过
adapt

adapt 搜索 · Codex、Claude

2,027,04023,125操作浏览器未明确通过
bolder

bolder 分析 · Codex、Claude

2,004,28823,130只读未明确通过
nano-banana-pro

纳米香蕉专业版 · 本页

1,9837接触敏感数据MIT通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Nano Banana Pro Image Generation & Editing

Generate and edit images using Google's Gemini 3 Pro model with advanced transparency support.

Prerequisites

  1. Dependencies: pip install google-genai Pillow numpy python-dotenv
  2. API Key: The script loads from .env automatically. Only ask the user if the script fails with "No API key found".

CLI Usage (REQUIRED)

ALWAYS use the CLI script. Do NOT write Python code or create.py files.

Run scripts/generate.py directly:

# Basic generation
python scripts/generate.py "a cute banana sticker" -o banana.png

# With transparency (for game assets, stickers, icons)
python scripts/generate.py "pixel art sword" -o sword.png --transparent

# Custom size and aspect ratio
python scripts/generate.py "game logo" -o logo.png --size 4K --ratio 16:9

Options:

  • -o, --output - Output filename (default: output.png)
  • --transparent - Extract true alpha channel using difference matting
  • --size - 1K, 2K, or 4K (default: 2K)
  • --ratio - Aspect ratio: 1:1, 16:9, 9:16, etc. (default: 1:1)
  • --model - Model override (default: gemini-3-pro-image-preview)

Note: The script loads the API key from .env automatically. Do not check for API keys manually or ask the user about them - just run the script and it will error with instructions if the key is missing.

Intent Detection

Analyze user request to determine:

IntentTriggersAction
Generate"create", "generate", "make", "draw", "design"Text-to-image
Edit"edit", "change", "modify", "update", "fix"Image-to-image
Transparency"transparent", "remove background", "alpha", "cutout", "PNG with transparency"Use difference matting
Text overlay"add text", "write on", "label", "caption"Use Gemini 3 Pro for accurate text

Resolution Selection

Choose resolution based on use case:

ResolutionBest ForPixel Output
1KQuick previews, thumbnails, web icons~1024px
2KSocial media, standard web images~2048px
4KPrint, professional assets, sprite sheets~4096px

Heuristics:

  • Sprite sheets, game assets, print materials → 4K
  • Social media, blog images, presentations → 2K
  • Quick tests, thumbnails, prototypes → 1K

When uncertain, ask user or default to 2K.

Aspect Ratios

Available: 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:9

Selection guide:

  • Square content (icons, avatars, social posts) → 1:1
  • Portrait (mobile, vertical video) → 9:16 or 3:4
  • Landscape (desktop, presentations) → 16:9 or 3:2
  • Cinematic/ultrawide → 21:9

Core Implementation

Basic Generation

from google import genai
from google.genai import types
from PIL import Image
import io

client = genai.Client()

response = client.models.generate_content(
    model="gemini-3-pro-image-preview",
    contents="Your descriptive prompt here",
    config=types.GenerateContentConfig(
        response_modalities=['IMAGE'],
        image_config=types.ImageConfig(
            aspect_ratio="1:1",  # or other ratio
            image_size="2K"     # 1K, 2K, or 4K
        ),
    ),
)

# Extract image from response
for part in response.parts:
    if part.inline_data is not None:
        image = Image.open(io.BytesIO(part.inline_data.data))
        image.save("output.png")
        break

Image Editing

# Load existing image
input_image = Image.open("input.png")

response = client.models.generate_content(
    model="gemini-3-pro-image-preview",
    contents=[
        input_image,
        "Edit instruction: Change the background to sunset colors"
    ],
    config=types.GenerateContentConfig(
        response_modalities=['TEXT', 'IMAGE'],
        image_config=types.ImageConfig(
            aspect_ratio="1:1",
            image_size="2K"
        ),
    ),
)

Multi-Turn Editing

Preserve context across edits using thought signatures:

# First edit
response1 = client.models.generate_content(
    model="gemini-3-pro-image-preview",
    contents=[image, "Add a red hat"],
    config=config,
)

# Continue editing (include previous response)
response2 = client.models.generate_content(
    model="gemini-3-pro-image-preview",
    contents=[
        image,
        "Add a red hat",
        response1,  # Include for context preservation
        "Now make the hat blue instead"
    ],
    config=config,
)

Transparency Extraction

When user needs transparent images, use difference matting. See scripts/transparency.py.

When to use:

  • User explicitly asks for transparency
  • Game sprites, icons, logos
  • Assets that will be composited
  • Cutouts and stickers

Process:

  1. Generate image on pure white background (#FFFFFF)
  2. Edit same image to pure black background (#000000)
  3. Calculate alpha from pixel differences
  4. Recover original colors

Key insight: Opaque pixels appear identical on both backgrounds (distance ≈ 0), transparent pixels show background color (max distance).

from scripts.transparency import extract_alpha_difference_matting

# After generating white and black background versions
final_image = extract_alpha_difference_matting(img_on_white, img_on_black)
final_image.save("output.png")  # RGBA with true transparency

Prompt Engineering

Fundamental Principle

"Describe the scene, don't just list keywords."

Narrative paragraphs outperform disconnected word lists.

Effective Prompt Structure

[Style/Medium] of [Subject] in [Context/Setting], [Lighting], [Additional details]

Examples:

# Photorealistic
A professional studio photograph of a brass steampunk pocket watch,
shot with a 50mm lens, soft diffused lighting from the left,
shallow depth of field with bokeh background, 4K HDR quality.

# Illustration
A detailed digital illustration of a medieval blacksmith's forge,
isometric perspective, warm orange glow from the furnace,
dieselpunk aesthetic with exposed pipes and riveted metal plates.

# Product mockup
A product photography shot of a ceramic coffee mug on a marble surface,
natural window lighting, minimalist Scandinavian style, clean white background.

Text in Images

For images containing text, use Gemini 3 Pro (not Imagen):

  • Keep text to 25 characters or less per element
  • Use 2-3 distinct text phrases maximum
  • Specify font style generally (bold, elegant, handwritten)
  • Indicate size (small, medium, large)

Quality Modifiers

Add these for enhanced output:

  • Photography: 4K, HDR, studio photo, professional lighting
  • Art: detailed, by a professional, high-quality illustration
  • General: high-fidelity, crisp details, polished finish

Error Handling

from google.genai import errors

def generate_with_retry(client, *, model, contents, config, max_attempts=5):
    for attempt in range(1, max_attempts + 1):
        try:
            return client.models.generate_content(
                model=model, contents=contents, config=config
            )
        except errors.APIError as e:
            code = getattr(e, "code", None) or getattr(e, "status", None)
            if code not in (429, 500, 502, 503, 504) or attempt >= max_attempts:
                raise
            delay = min(30, 2 ** (attempt - 1))
            time.sleep(delay)

Model Selection

ModelUse Case
gemini-3-pro-image-previewComplex edits, text rendering, multi-turn, transparency workflows
gemini-2.5-flash-imageQuick generation, high volume, simple tasks
imagen-4.0-generate-001Photorealistic images, no editing needed

Default to gemini-3-pro-image-preview for most tasks.

File References

  • scripts/generate.py - CLI for image generation (use this instead of writing code)
  • scripts/transparency.py - Difference matting implementation
  • references/prompts.md - Extended prompt examples by category

适合场景

01

文本生成图片

02

图片风格化

03

产品图和创意图

04

需要 FLUX 模型时

能力概览

能力 1

调用 FLUX 图像模型

能力 2

支持文本生图和图像改写

能力 3

覆盖 LoRA 或风格适配

能力 4

适合创意视觉生成

平台分布

Claude Code

26.41%
按下载量换算168

Codex

23.13%
按下载量换算147

trae

18.65%
按下载量换算118

Antigravity

13%
按下载量换算83

windsurf

7.77%
按下载量换算49

Gemini CLI

3.29%
按下载量换算21

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

继续浏览同类 Skills