refactor: group mm_embeddings per sequence at worker output.#1986
Open
wly-115 wants to merge 1 commit into
Open
refactor: group mm_embeddings per sequence at worker output.#1986wly-115 wants to merge 1 commit into
wly-115 wants to merge 1 commit into
Conversation
wly-115
requested review from
Clement-Wang26,
DongheJin,
DragonFive,
JimHsiung,
Kang-Meng,
RobbieLeung,
XuZhang99,
liujinguang0125,
liutongxuan,
walsonyang,
xiao-yu-chen,
yingxudeng,
yq33victor and
zhang-minchao
as code owners
July 21, 2026 03:37
wly-115
marked this pull request as draft
July 21, 2026 03:38
wly-115
force-pushed
the
refactor/mm_emebdding
branch
2 times, most recently
from
July 21, 2026 07:12
dc6ad0e to
b6fda38
Compare
wly-115
marked this pull request as ready for review
July 21, 2026 07:15
wly-115
force-pushed
the
refactor/mm_emebdding
branch
from
July 21, 2026 09:12
b6fda38 to
fccaef6
Compare
Co-Authored-By: Claude <noreply@anthropic.com>
wly-115
force-pushed
the
refactor/mm_emebdding
branch
from
July 21, 2026 12:46
fccaef6 to
98c315b
Compare
xiao-yu-chen
approved these changes
Jul 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Move multimodal embedding grouping from the batch consumer into the worker
output.
SampleOutput.mm_embeddingsis now grouped by sequence(
vector<vector<Tensor>>, outer = sequence, inner = one tensor per encodeditem in that sequence: images for mm_embed, the full hidden for the
full-embedding task), and each sequence's embeddings are carried on its own
RawSampleOutput. Serialization (shared memory and RPC) now maps the outersequence to
outputs[i]instead of re-slicing a batch-level tensor list inthe consumer.
Related Issues
Change Type
Pull Request Checklist
Thank you for contributing to xLLM. Before requesting review, please make sure the following items are complete.
PR Title and Commit Messages
<type>: <subject>.Pre-commit Checks
pre-commitby runningpip install pre-commitor an equivalent command.pre-commit install.pre-commit run --all-filesand fixed any reported issues.Self Review
.agents/skills/code-review/references/custom-code-style.md, especially code written or assisted by AI.mainbranch.Build and Test Coverage
python setup.py build testhas passed on a CUDA machine.python setup.py build testhas passed on an NPU machine.python setup.py build testhas passed on an MLU machine.Reviewer Notes