From 7391db62d10f74c4f44d0e57a04c1b846ab4fa28 Mon Sep 17 00:00:00 2001 From: Roger Wang Date: Sun, 30 Nov 2025 16:45:30 -0800 Subject: [PATCH] [Doc] Cleanup non-english comments (#125) Signed-off-by: Roger Wang --- docs/design/vllm_omni_design.md | 10 +++++----- .../offline_inference/qwen2_5_omni/extract_prompts.py | 2 +- .../model_executor/models/qwen3_omni/qwen3_omni.py | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/docs/design/vllm_omni_design.md b/docs/design/vllm_omni_design.md index 840106203..eeb78997b 100644 --- a/docs/design/vllm_omni_design.md +++ b/docs/design/vllm_omni_design.md @@ -449,15 +449,15 @@ AsyncLLM.add_request() ↓ OutputProcessor.add_request() ↓ -RequestState.from_new_request() → 创建请求状态 +RequestState.from_new_request() → create request state -AsyncLLM.__init__() / AsyncLLM.generate() / AsyncLLM.encode() → 创建一个Background loop 持续从EngineCore获取输出 +AsyncLLM.__init__() / AsyncLLM.generate() / AsyncLLM.encode() → create a background loop that continuously pulls output from EngineCore ↓ -OutputProcessor.process_outputs() → 更新状态并处理输出 +OutputProcessor.process_outputs() → update state and process outputs ↓ -RequestState.make_request_output() → 转换为最终输出,格式为RequestOutput或者PoolingRequestOutput +RequestState.make_request_output() → convert to the final output, formatted as RequestOutput or PoolingRequestOutput ↓ -RequestOutputCollector.put() → 推送到队列(AsyncLLM) +RequestOutputCollector.put() → push to the queue (AsyncLLM) ``` Need to add implementation for an existing method diff --git a/examples/offline_inference/qwen2_5_omni/extract_prompts.py b/examples/offline_inference/qwen2_5_omni/extract_prompts.py index 3d940b995..574dd0544 100644 --- a/examples/offline_inference/qwen2_5_omni/extract_prompts.py +++ b/examples/offline_inference/qwen2_5_omni/extract_prompts.py @@ -4,7 +4,7 @@ from typing import Optional def extract_prompt(line: str) -> Optional[str]: - # 提取第一个 '|' 与第二个 '|' 之间的内容 + # Extract the content between the first '|' and the second '|' i = line.find("|") if i == -1: return None diff --git a/vllm_omni/model_executor/models/qwen3_omni/qwen3_omni.py b/vllm_omni/model_executor/models/qwen3_omni/qwen3_omni.py index 2709028ad..11aeb44d1 100644 --- a/vllm_omni/model_executor/models/qwen3_omni/qwen3_omni.py +++ b/vllm_omni/model_executor/models/qwen3_omni/qwen3_omni.py @@ -519,9 +519,9 @@ class Qwen3OmniMoeForConditionalGeneration( tts_eos_thinker=tts_eos_thinker, tts_pad_thinker=tts_pad_thinker, ) - # req_embeds: [S,D], req_input_ids: [S] → map到当前 span + # req_embeds: [S,D], req_input_ids: [S] → map onto the current span seg_len = min(span_len, req_embeds.shape[0]) - # 强制对齐 dtype/device/内存布局,避免精度或布局差异导致比较不相等 + # Force-align dtype/device/memory layout to avoid mismatches from precision or layout differences inputs_embeds[s : s + seg_len] = ( req_embeds[:seg_len].to(device=inputs_embeds.device, dtype=inputs_embeds.dtype).contiguous() )