-
Notifications
You must be signed in to change notification settings - Fork 2.9k
fix(openai/0.x): handle OpenRouter image generation responses #8880
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
fix(openai/0.x): handle OpenRouter image generation responses #8880
Conversation
- Add support for OpenRouter's image generation API response format - Extract images from OpenRouter's `choices[0].message.images` array - Convert images to LangChain's Multimodal.Image content blocks - Add unit tests for single image, multiple images, and text-only responses - Use proper TypeScript types for content blocks OpenRouter returns generated images in a separate `images` array rather than within the message content. This fix ensures these images are properly extracted and converted to LangChain's standard multimodal message format. Fixes: #8791
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
hntrl
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
everything but the standard type change should be relevant for this PR also:
|
Updated PR in the same way as #8879 |
backported from #8879