post-prompt-editing-inferences
Edit images using AI by applying text prompts to modify content, adjust styles, or transform visual elements.
Instructions
Edit an image with a prompt.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| originalAssets | No | If set to true, returns the original asset without transformation | |
| dryRun | No | ||
| image | Yes | The image to edit. Must reference an existing AssetId or be a data URL. | |
| referenceImages | No | ||
| seed | No | The seed to use for the image generation. Only available for the `flux-kontext` model. | |
| strength | No | The strength Only available for the `flux-kontext` LoRA model. | |
| guidanceScale | No | The guidance scale to use for the image generation. Only available for the `flux-kontext` model. | |
| modelId | No | The model to use. Can be "gemini-2.0-flash", "gemini-2.5-flash", "gpt-image-1", "flux-kontext", "runway-gen4-image" or "seedream-4". | |
| format | No | The format of the generated image(s) This parameter is only supported for the `gpt-image-1` model. | |
| aspectRatio | No | The aspect ratio of the generated image(s). Supported for: `gemini-2.5-flash`, `gpt-image-1`, `flux-kontext`, `runway-gen4-image`, `seedream-4`. Will default to `auto` for other models and unknown ratios. Notes: - `gemini-2.5-flash` supports Landscape: 21:9, 16:9, 4:3, 3:2 • Square: 1:1 • Portrait: 9:16, 3:4, 2:3 • Flexible: 5:4, 4:5 • `auto`. - `gpt-image-1` supports `1:1`, `3:2`, `2:3`, `auto` (unknown ratios fall back to `auto`). - `runway-gen4-image` supports `1:1`, `4:3`, `3:4`, `16:9`, `9:16`, `auto` (unknown ratios fall back to `auto`). - `seedream-4` supports `1:1`, `4:3`, `3:4`, `16:9`, `9:16`, `2:3`, `3:2`, `21:9`, `auto`. | |
| inputFidelity | No | When set to `high`, allows to better preserve details from the input images in the output. This is especially useful when using images that contain elements like faces or logos that require accurate preservation in the generated image. You can provide multiple input images that will all be preserved with high fidelity, but keep in mind that the first image will be preserved with richer textures and finer details, so if you include elements such as faces, consider placing them in the first image. Only available for the `gpt-image-1` model. | |
| quality | No | The quality of the generated image(s). Only available for the `gpt-image-1`, `flux-kontext`, `runway-gen4-image` and `seedream-4` models. | |
| concepts | No | ||
| numSamples | No | The number of samples to generate Maximum depends on the subscription tier. | |
| compression | No | The compression level (0-100%) for the generated images. This parameter is only supported for the `gpt-image-1` model with the `webp` or `jpeg` output formats, and defaults to 100. | |
| prompt | Yes | The prompt to edit the given image. | |
| mask | No | You can provide a mask to indicate where the image should be edited. The black area of the mask will be replaced, while the filled areas will be kept as is. Must reference an existing AssetId or be a data URL. Only available for the `gpt-image-1` model. Will be ignored for other models. |