Image Generation
Generate images using the generate_image tool.
Parameters
| Parameter |
Type |
Required |
Description |
prompt |
string |
yes |
Detailed description of the image |
filename |
string |
yes |
Output filename (e.g. poster.png) |
aspect_ratio |
string |
no |
1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 4:5, 5:4, 21:9 |
size |
string |
no |
1K (default), 2K, 4K |
reference_images |
array |
no |
Storage paths to reference images |
style |
string |
no |
Style hint (e.g. photorealistic, illustration) |
negative_prompt |
string |
no |
What to avoid (e.g. blurry, watermark) |
google_search |
boolean |
no |
Enable real-time data grounding |
Prompt Structure
Build prompts with these 5 components:
- Style/medium — photograph, illustration, watercolor, digital art, vector, 3D render
- Subject — who or what, with specific details (pose, clothing, expression, material)
- Setting — location, time of day, atmosphere, weather
- Action — what is happening in the scene
- Composition — camera angle, framing (close-up, wide shot, bird's eye, low angle)
Example: "Cinematic photograph of a futuristic city skyline at golden hour, with flying vehicles crossing between skyscrapers, shot from a rooftop balcony with shallow depth of field, warm amber tones"
Aspect Ratio Guide
Choose based on the intended use:
1:1 — social media posts (Instagram feed, profile pictures)
16:9 — banners, landscape, YouTube thumbnails, presentations
9:16 — stories, reels, vertical mobile content
4:3 — classic photo, presentations
3:2 — standard photography
4:5 — Instagram portrait posts
21:9 — ultrawide cinematic banners
Reference Images
Reference images provide visual context. The model sees them BEFORE the text prompt.
For logos and brand assets:
- Add the logo path to
reference_images
- In the prompt, be explicit: "Place the provided logo at the bottom center of the image. Do not modify the logo's shape, colors, or proportions — use it exactly as provided, only resize it to fit the composition"
- Never describe what the logo looks like — just describe where and how to use it
For style references:
- Add the style image to
reference_images
- In the prompt: "Generate in the same visual style as the provided reference image"
For editing existing images:
- Add the image to
reference_images
- Describe the desired changes: "Change the background to a sunset beach scene while keeping the subject unchanged"
Text in Images
- Enclose exact text in quotes:
Write the text "SALE 50% OFF"
- Describe typography explicitly: "bold white sans-serif font with a subtle drop shadow"
- Specify placement: "centered at the top of the image"
- Keep text minimal for social media — one headline maximum to avoid clutter
Google Search Grounding
Set google_search: true when the image needs real-time or factual data:
- Stock prices and financial charts
- Weather forecasts
- Current events and news topics
- Sports scores and standings
- Real product data
Example: "Visualize the Bitcoin price trend over the last 7 days as an infographic"
Quality Tips
- Be descriptive, not repetitive. Don't use "4K, masterpiece, trending on artstation" — the model understands natural language. Describe the scene vividly instead.
- Use photographic language for realistic images: camera model, focal length (85mm f/1.4), lighting setup (soft key light with rim light), film stock (Kodak Portra 400)
- Be specific about colors and materials: "matte black aluminum with brushed gold accents" instead of just "dark with gold"
- Resolution matters: Use
size: "2K" for social media, size: "4K" for print-quality assets
- Composition keywords: rule of thirds, symmetrical, leading lines, negative space, flat lay, isometric
What NOT to Do
- Don't describe reference images — just describe how to USE them
- Don't add quality spam keywords — focus on scene description
- Don't leave aspect ratio unset for social media — always pick the right ratio
- Don't put too much text in the prompt for text-in-image — keep it to one headline
- Don't forget to use
google_search when the image needs current real-world data
After Generation
Always share the saved file URL with the user so they can preview the result.
1---2name: image-generation3description: Generate images from text descriptions using AI. Use when the user asks to create, generate, draw, or design an image, illustration, icon, or any visual content.4---56# Image Generation78Generate images using the `generate_image` tool.910## Parameters1112| Parameter | Type | Required | Description |13|-----------|------|----------|-------------|14| `prompt` | string | yes | Detailed description of the image |15| `filename` | string | yes | Output filename (e.g. `poster.png`) |16| `aspect_ratio` | string | no | `1:1`, `16:9`, `9:16`, `4:3`, `3:4`, `3:2`, `2:3`, `4:5`, `5:4`, `21:9` |17| `size` | string | no | `1K` (default), `2K`, `4K` |18| `reference_images` | array | no | Storage paths to reference images |19| `style` | string | no | Style hint (e.g. `photorealistic`, `illustration`) |20| `negative_prompt` | string | no | What to avoid (e.g. `blurry, watermark`) |21| `google_search` | boolean | no | Enable real-time data grounding |2223## Prompt Structure2425Build prompts with these 5 components:26271. **Style/medium** — photograph, illustration, watercolor, digital art, vector, 3D render282. **Subject** — who or what, with specific details (pose, clothing, expression, material)293. **Setting** — location, time of day, atmosphere, weather304. **Action** — what is happening in the scene315. **Composition** — camera angle, framing (close-up, wide shot, bird's eye, low angle)3233Example: "Cinematic photograph of a futuristic city skyline at golden hour, with flying vehicles crossing between skyscrapers, shot from a rooftop balcony with shallow depth of field, warm amber tones"3435## Aspect Ratio Guide3637Choose based on the intended use:3839- `1:1` — social media posts (Instagram feed, profile pictures)40- `16:9` — banners, landscape, YouTube thumbnails, presentations41- `9:16` — stories, reels, vertical mobile content42- `4:3` — classic photo, presentations43- `3:2` — standard photography44- `4:5` — Instagram portrait posts45- `21:9` — ultrawide cinematic banners4647## Reference Images4849Reference images provide visual context. The model sees them BEFORE the text prompt.5051**For logos and brand assets:**52- Add the logo path to `reference_images`53- In the prompt, be explicit: "Place the provided logo at the bottom center of the image. Do not modify the logo's shape, colors, or proportions — use it exactly as provided, only resize it to fit the composition"54- Never describe what the logo looks like — just describe where and how to use it5556**For style references:**57- Add the style image to `reference_images`58- In the prompt: "Generate in the same visual style as the provided reference image"5960**For editing existing images:**61- Add the image to `reference_images`62- Describe the desired changes: "Change the background to a sunset beach scene while keeping the subject unchanged"6364## Text in Images6566- Enclose exact text in quotes: `Write the text "SALE 50% OFF"`67- Describe typography explicitly: "bold white sans-serif font with a subtle drop shadow"68- Specify placement: "centered at the top of the image"69- Keep text minimal for social media — one headline maximum to avoid clutter7071## Google Search Grounding7273Set `google_search: true` when the image needs real-time or factual data:74- Stock prices and financial charts75- Weather forecasts76- Current events and news topics77- Sports scores and standings78- Real product data7980Example: "Visualize the Bitcoin price trend over the last 7 days as an infographic"8182## Quality Tips8384- **Be descriptive, not repetitive.** Don't use "4K, masterpiece, trending on artstation" — the model understands natural language. Describe the scene vividly instead.85- **Use photographic language** for realistic images: camera model, focal length (85mm f/1.4), lighting setup (soft key light with rim light), film stock (Kodak Portra 400)86- **Be specific about colors and materials:** "matte black aluminum with brushed gold accents" instead of just "dark with gold"87- **Resolution matters:** Use `size: "2K"` for social media, `size: "4K"` for print-quality assets88- **Composition keywords:** rule of thirds, symmetrical, leading lines, negative space, flat lay, isometric8990## What NOT to Do9192- Don't describe reference images — just describe how to USE them93- Don't add quality spam keywords — focus on scene description94- Don't leave aspect ratio unset for social media — always pick the right ratio95- Don't put too much text in the prompt for text-in-image — keep it to one headline96- Don't forget to use `google_search` when the image needs current real-world data9798## After Generation99100Always share the saved file URL with the user so they can preview the result.