AgentSkillsCN

Nano Image Generator

纳米图像生成器

SKILL.md

Nano Image Generator

Generate images using Gemini 3 Pro Preview (Nano Banana Pro) for app icons, UI graphics, marketing assets, and illustrations.

Usage

bash
python .claude/skills/nano-image-generator/scripts/generate_image.py "<prompt>" --output <path> [options]

Required

  • prompt - Image description
  • --output, -o - Output file path

Options

  • --aspect, -a - Aspect ratio (default: 1:1)
    • Square: 1:1
    • Portrait: 2:3, 3:4, 4:5, 9:16
    • Landscape: 3:2, 4:3, 5:4, 16:9, 21:9
  • --size, -s - Resolution: 1K, 2K (default), 4K
  • --ref, -r - Reference image path (can use multiple times, max 14)

Examples

bash
# Simple icon
python .claude/skills/nano-image-generator/scripts/generate_image.py "A minimalist app icon for a fitness tracker, gold and black colors" --output ./assets/icon.png

# Marketing banner
python .claude/skills/nano-image-generator/scripts/generate_image.py "Hero image for workout app, athletic theme" --output ./marketing/hero.png --aspect 16:9 --size 4K

# With reference image for style consistency
python .claude/skills/nano-image-generator/scripts/generate_image.py "Same style, but showing a runner" --output ./assets/runner.png --ref ./assets/existing-style.png

Environment

Requires GOOGLE_AI_API_KEY environment variable. Add to your .env file:

code
GOOGLE_AI_API_KEY=your_key_here

Prompt Tips

  • Be specific about style: "flat design", "3D render", "watercolor"
  • Include colors: "gold and black", "vibrant blues"
  • Specify context: "app icon", "marketing banner", "UI illustration"
  • For consistency, use --ref with existing project images