fix(grpc): update vLLM imports for inputs reorganization#1033
fix(grpc): update vLLM imports for inputs reorganization#1033CatherineSue merged 4 commits intomainfrom
Conversation
vLLM upstream (#35182) reorganized multimodal input types: - MultiModalInputs -> MultiModalInput (moved to vllm.inputs.engine) - mm_inputs() -> mm_input() (moved to vllm.inputs.engine) Update the gRPC servicer imports and usages to match. This change is prepared ahead of the vLLM release that includes the reorganization and should be merged when that version is available. Signed-off-by: Chang Su <chang.s.su@oracle.com> # Conflicts: # grpc_servicer/smg_grpc_servicer/vllm/servicer.py
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughReplaced vLLM input constructors in the gRPC servicer: switched tokenized prompt import to Changes
Sequence Diagram(s)(omitted) Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Code Review
This pull request updates the vLLM multimodal input handling by migrating from the deprecated mm_inputs and MultiModalInputs to the newer mm_input and MultiModalInput classes from vllm.inputs.engine. These changes include updating imports, return type hints, and function calls within the _build_preprocessed_mm_inputs method. I have no feedback to provide.
…nization Part of the vLLM #35182 reorganization that moved symbols from vllm.inputs.data to vllm.inputs.engine with renames. Signed-off-by: Chang Su <chang.s.su@oracle.com>
Signed-off-by: Chang Su <chang.s.su@oracle.com>
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@grpc_servicer/smg_grpc_servicer/vllm/servicer.py`:
- Around line 18-19: The project imports VllmMultiModalInput, mm_input, and
tokens_input from vllm (in grpc_servicer/smg_grpc_servicer/vllm/servicer.py),
which require vllm>=0.19.0; update the dependency constraint in
grpc_servicer/pyproject.toml by changing the vllm requirement to vllm =
["vllm>=0.19.0"] so the installed vllm release matches the new API
reorganization.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
Run ID: c8443587-019b-4c52-8cea-1408800ea702
📒 Files selected for processing (1)
grpc_servicer/smg_grpc_servicer/vllm/servicer.py
The new imports from vllm.inputs.engine require vLLM >=0.19.0. Signed-off-by: Chang Su <chang.s.su@oracle.com>
Description
Problem
vLLM reorganized its inputs module in
vllm-project/vllm#35182(commitba2f0acc2, 2026-03-25), renaming and relocating several symbols. This change first appeared inv0.18.2rc0and is now officially released inv0.19.0:vllm.multimodal.inputs.mm_inputs→vllm.inputs.engine.mm_inputvllm.multimodal.inputs.MultiModalInputs→vllm.inputs.engine.MultiModalInputvllm.inputs.token_inputs→vllm.inputs.engine.tokens_inputThe gRPC servicer was importing the old names, which breaks on vLLM >= v0.19.0.
Solution
Update the gRPC servicer imports to use the new module paths and renamed symbols from
vllm.inputs.engine.Changes
grpc_servicer/smg_grpc_servicer/vllm/servicer.py:MultiModalInput(wasMultiModalInputs) fromvllm.inputs.enginemm_input(wasmm_inputs) fromvllm.inputs.enginetokens_input(wastoken_inputs) fromvllm.inputs.engineTest Plan
Checklist
cargo +nightly fmtpassescargo clippy --all-targets --all-features -- -D warningspassesSummary by CodeRabbit