Skip to content

Conversation

@nrghosh
Copy link
Contributor

@nrghosh nrghosh commented Oct 22, 2025

Fixes #57978

  • Fixed get_optional_input_keys() to declare 'image' (singular) instead of 'images'
  • Added clear error message and fix when users provide 'images' field in the custom path (has_image = False)

Fixes ray-project#57978

- Fixed get_optional_input_keys() to declare 'image' (singular) instead of 'images'
- Added clear error message and fix when users provide 'images' field in
  the custom path (`has_image = False`)

Signed-off-by: Nikhil Ghosh <nikhil@anyscale.com>
@nrghosh nrghosh self-assigned this Oct 22, 2025
@nrghosh nrghosh added the go add ONLY when ready to merge, run all tests label Oct 22, 2025
# Extract image data from preprocessing output
if "image" in row:
image = row.pop("image")
elif "images" in row:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is weird, I am inclined to not throw any errors and dump it on the user to do it right.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree - calling it deprecated is also not quite right. Can just keep behavior as it was before, and include just the doc fix for clarification (so at least internally, we are consistent)?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah let's keep the old one.

return {
"tokenized_prompt": "The tokenized prompt. If provided, the prompt will not be tokenized by the vLLM engine.",
"images": "The images to generate text from. If provided, the prompt will be a multimodal prompt.",
"image": "The image(s) for multimodal input. Accepts a single image or list of images.",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok.

Signed-off-by: Nikhil Ghosh <nikhil@anyscale.com>
@nrghosh nrghosh marked this pull request as ready for review October 22, 2025 02:02
@nrghosh nrghosh requested a review from a team as a code owner October 22, 2025 02:02
@kouroshHakha kouroshHakha changed the title [data][llm] Fix vLLMEngineStage field name inconsistency for images [bugfix][data][llm] Fix vLLMEngineStage field name inconsistency for images Oct 22, 2025
@kouroshHakha kouroshHakha enabled auto-merge (squash) October 22, 2025 03:00
@kouroshHakha kouroshHakha merged commit 10ff03a into ray-project:master Oct 22, 2025
7 checks passed
@anindya-saha
Copy link

Thank you @nrghosh for helping to integrate qwen_vl_utils. This can help showcase how to make custom pre-processing using Qwen 2.5 VL processor work with Ray Data LLM. I will be using that as an use case my talk at the Ray Summit '25. Ref slack thread and slack thread.

Aydin-ab pushed a commit to Aydin-ab/ray-aydin that referenced this pull request Nov 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

go add ONLY when ready to merge, run all tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[data][llm] - vLLMEngineStage has inconsistent field name for images (singular vs plural)

3 participants