Overview
Creates an edited or extended image given one or more source images and a prompt, using OpenAI’s gpt-image-1 model.- Output Type: image
- Estimated Cost: quality == “high” ? 16 : 8 credits
- Handler: modal
Parameters
Required Parameters
The image(s) to edit. Must be png, webp, or jpg files less than 25MB each.
- Label: Input Image(s)
A description of what you want the model to do with your images.
Max length 32000 characters.
- Label: Prompt
The size of the generated images. Must be one of ‘1024x1024’, ‘1536x1024’ (landscape), ‘1024x1536’ (portrait), or ‘auto’. Defaults to auto.
- Label: Size
- Options:
1024x1024
,1536x1024
,1024x1536
,auto
Optional Parameters
An optional image mask. White areas indicate where the image should be edited. Must be a PNG file, less than 4MB, and have the same dimensions as the first input image.
- Label: Mask (optional)
Number of samples to generate
This is the number of tries to generate for the prompt.
If you get a request for n_samples > 1, you are still using a single prompt for the whole set.
- Label: Number of samples
- Minimum: 1
- Maximum: 4
How strongly to preserve the input image’s content (high, medium, low, auto). Defaults to auto.
This is useful for preserving the original details like text, faces, logos, etc.
- Label: Input Fidelity
- Options:
high
,medium
,low
,auto
A unique identifier representing your end-user for enabling per-user content monitoring.
- Label: User ID