Image Generation
Generate images from text prompts and edit existing images using OpenAI’s DALL-E API. Ideal for marketing, design assistants, and content creation agents.Reuses the
openai peer dependency (already present if using OpenAI models).Quick Start
Config
OpenAI API key. Falls back to
OPENAI_API_KEY env var.DALL-E model to use (
dall-e-2 or dall-e-3).Default image size. Options:
256x256, 512x512, 1024x1024, 1792x1024, 1024x1792.Image quality (
standard or hd). HD is only available for DALL-E 3.Tools
| Tool | Description |
|---|---|
image_generate | Generate an image from a text prompt. Returns URL(s) and revised prompt. |
image_edit | Edit an existing image with a text prompt (inpainting). Provide the original image URL. |
Model Comparison
| Feature | DALL-E 2 | DALL-E 3 |
|---|---|---|
| Sizes | 256x256, 512x512, 1024x1024 | 1024x1024, 1792x1024, 1024x1792 |
| Quality | Standard | Standard, HD |
| Prompt Following | Good | Excellent |
| Image Editing | Yes | No |
| Batch (n > 1) | Yes | No |
Environment Variables
| Variable | Description |
|---|---|
OPENAI_API_KEY | OpenAI API key |