Generate and edit images via Google Gemini API for OpenClaw. Supports Gemini native generation, Imagen 3, style presets, and batch generation with HTML gallery. Zero dependencies.

- Dual engine — Gemini native (generation + editing) and Imagen 3 (high-quality generation)
- Style presets — photo, anime, watercolor, cyberpunk, minimalist, oil-painting, pixel-art, sketch, 3d-render, pop-art
- Image editing — Edit existing images with text prompts (Gemini engine)
- Batch generation — Generate multiple images with automatic HTML gallery
- Zero dependencies — Pure Python stdlib, no pip install needed
export GEMINI_API_KEY="your-key-here"
# Generate with random prompts
python3 scripts/gen.py
# Custom prompt with style
python3 scripts/gen.py --prompt "a cyberpunk cat in Tokyo" --style anime
# Imagen 3 engine
python3 scripts/gen.py --engine imagen --count 4 --aspect 16:9
# Edit an existing image
python3 scripts/gen.py --edit photo.png --prompt "make it watercolor style"
npx clawhub install gemini-image-gen
git clone https://github.com/IISweetHeartII/gemini-image-gen.git
| Style |
Description |
photo |
Ultra-detailed photorealistic photography, 8K resolution |
anime |
Studio Ghibli inspired, vibrant colors |
watercolor |
Delicate watercolor on textured paper |
cyberpunk |
Neon-lit, rain-soaked Blade Runner aesthetic |
minimalist |
Clean geometric shapes, limited palette |
oil-painting |
Classical with visible brushstrokes |
pixel-art |
Retro 16-bit style |
sketch |
Pencil sketch with hatching |
3d-render |
Professional 3D with global illumination |
pop-art |
Bold Ben-Day dots, strong outlines |
MIT