Skip to content

Add multi-image upload #590

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 4 commits into
base: main
Choose a base branch
from
Open

Add multi-image upload #590

wants to merge 4 commits into from

Conversation

alexrudall
Copy link
Owner

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?

@fearlessfrog
Copy link

This works nicely for me with image array inputs e.g.

      client = OpenAI::Client.new
      response = client.images.edit(
        parameters: {
          model: "gpt-image-1",
          image: [File.open(base_image_path, "rb"), File.open(logo_image_path, "rb")],
          prompt: "Take the first image as base and apply the second image as a watermark on the bottom right corner",
          size: "1024x1024"
          # Removed response_format parameter as it's not supported with gpt-image-1
        }
      )

Thanks!

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.

2 participants