Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/openai/types/image_edit_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class ImageEditParamsBase(TypedDict, total=False):
image: Required[Union[FileTypes, SequenceNotStr[FileTypes]]]
"""The image(s) to edit. Must be a supported image file or an array of images.

For the GPT image models (`gpt-image-1`, `gpt-image-1-mini`, and
For the GPT image models (`gpt-image-1`, `gpt-image-1-mini`, `gpt-image-2`, and
`gpt-image-1.5`), each image should be a `png`, `webp`, or `jpg` file less than
50MB. You can provide up to 16 images. `chatgpt-image-latest` follows the same
input constraints as GPT image models.
Expand Down Expand Up @@ -46,7 +46,7 @@ class ImageEditParamsBase(TypedDict, total=False):
"""
Control how much effort the model will exert to match the style and features,
especially facial features, of input images. This parameter is only supported
for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for
for `gpt-image-1.5` and later models (including `gpt-image-2`), unsupported for
`gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.
"""

Expand Down
2 changes: 1 addition & 1 deletion src/openai/types/image_generate_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class ImageGenerateParamsBase(TypedDict, total=False):
"""The model to use for image generation.

One of `dall-e-2`, `dall-e-3`, or a GPT image model (`gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`). Defaults to `dall-e-2` unless a parameter
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`). Defaults to `dall-e-2` unless a parameter
specific to the GPT image models is used.
"""

Expand Down
2 changes: 1 addition & 1 deletion src/openai/types/image_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

__all__ = ["ImageModel"]

ImageModel: TypeAlias = Literal["gpt-image-1.5", "dall-e-2", "dall-e-3", "gpt-image-1", "gpt-image-1-mini"]
ImageModel: TypeAlias = Literal["gpt-image-1.5", "dall-e-2", "dall-e-3", "gpt-image-1", "gpt-image-1-mini", "gpt-image-2"]
4 changes: 2 additions & 2 deletions src/openai/types/responses/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ class ImageGeneration(BaseModel):
"""
Control how much effort the model will exert to match the style and features,
especially facial features, of input images. This parameter is only supported
for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for
for `gpt-image-1.5` and later models (including `gpt-image-2`), unsupported for
`gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.
"""

Expand All @@ -267,7 +267,7 @@ class ImageGeneration(BaseModel):
Contains `image_url` (string, optional) and `file_id` (string, optional).
"""

model: Union[str, Literal["gpt-image-1", "gpt-image-1-mini", "gpt-image-1.5"], None] = None
model: Union[str, Literal["gpt-image-1", "gpt-image-1-mini", "gpt-image-1.5", "gpt-image-2"], None] = None
"""The image generation model to use. Default: `gpt-image-1`."""

moderation: Optional[Literal["auto", "low"]] = None
Expand Down
4 changes: 2 additions & 2 deletions src/openai/types/responses/tool_param.py
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ class ImageGeneration(TypedDict, total=False):
"""
Control how much effort the model will exert to match the style and features,
especially facial features, of input images. This parameter is only supported
for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for
for `gpt-image-1.5` and later models (including `gpt-image-2`), unsupported for
`gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.
"""

Expand All @@ -267,7 +267,7 @@ class ImageGeneration(TypedDict, total=False):
Contains `image_url` (string, optional) and `file_id` (string, optional).
"""

model: Union[str, Literal["gpt-image-1", "gpt-image-1-mini", "gpt-image-1.5"]]
model: Union[str, Literal["gpt-image-1", "gpt-image-1-mini", "gpt-image-1.5", "gpt-image-2"]]
"""The image generation model to use. Default: `gpt-image-1`."""

moderation: Literal["auto", "low"]
Expand Down