Skip to content

Add support for multiple image files in CreateImageEditRequest #366

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

spantaleev
Copy link

Fixes #363

@64bit
Copy link
Owner

64bit commented Jun 1, 2025

Thank you for the PR!

This can be improved to match the spec image string or array Required
https://github.com/openai/openai-openapi/blob/master/openapi.yaml#L21129-L21137

That's because a user can input a single or multiple images in builder like:

single image

  CreateImageEditRequestArgs::default()
     .image(single_image)
     ...
    .build()?

multiple image

  CreateImageEditRequestArgs::default()
     .image([image1, image2])  # this can be vector, or just [] 
     ...
    .build()?

There are pattern in the repo which makes it happen in other places, and then implement From traits to have API like above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CreateImageEditRequest only deals with a single image
2 participants