generating-images

Generate images with the Gemini API and save PNGs to a repository.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/blackjiro/dotfiles --skill generating-images
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: generating-images
Source: https://github.com/blackjiro/dotfiles/tree/main/dot_claude/skills/generating-images
Command: npx skills add https://github.com/blackjiro/dotfiles --skill generating-images

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires google-genai, Pillow, and includes scripts (resource) components.

What problem does it solve?

This skill automates image generation using the Gemini API and stores the resulting assets in your repository, streamlining the creation of visual content for sites, apps, and marketing.

Core Features & Use Cases

  • Automated image generation: Generate high-quality images from descriptive prompts using Gemini's flash and pro models.
  • Flexible outputs: Supports multiple aspect ratios (1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3) to fit landing pages, hero sections, product images, avatars, and placeholders.
  • Seamless asset management: Saves generated PNGs directly into your project/assets directory for immediate integration.

Quick Start

Set your Gemini API key and generate an image with a descriptive prompt. Example: export GEMINI_API_KEY="your-api-key" python ~/.claude/skills/generating-images/scripts/generate_image.py --prompt "A modern hero image for a tech startup" --output "./assets/images/hero.png" --aspect-ratio "16:9"

Frequently Asked Questions about generating-images

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate AI images and save them directly to my repository?

You can generate AI images and save them to your repository by running a Python script that uses the Gemini API to create visuals from descriptive prompts and outputs them as PNG files into your project directory.

Can I use the Gemini API to create hero images with specific aspect ratios for landing pages?

Yes, the Gemini API supports creating hero images with specific aspect ratios for landing pages, offering flexible dimensions like 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, and 2:3 to fit various marketing and product workflows.

What do I need to set up before generating images with the Gemini API?

Before generating images with the Gemini API, you need to set the GEMINI_API_KEY environment variable and ensure the google-genai and Pillow Python libraries are installed for API access and optional reference-image handling.

Does this image generation approach work for creating product photos and avatars?

Yes, this image generation approach works for creating product photos and avatars, applying Gemini's flash and pro models to produce high-quality visual assets suitable for marketing campaigns and application interfaces.

Are there limitations when using Pillow for reference-image handling in AI image generation?

Pillow is used optionally for reference-image handling during AI image generation, meaning it is not required for basic prompt-to-image tasks but may limit reference processing capabilities if omitted from your Python environment.