@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / f4962a6d55
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 14, 05:30 UTC

[Doc]: fix typos in Python comments (#24417)

Signed-off-by: Didier Durand <durand.didier@gmail.com>

Didier Durand committed Sep 8, 2025 at 09:22 UTC f4962a6d55a340ebb569d377c842deff7611d8f7
12 files changed +12 -12
examples/offline_inference/chat_with_tools.py
+1 -1
@@ -143,5 +143,5 @@ outputs = llm.chat(messages, sampling_params, tools=tools)
143
144 print(outputs[0].outputs[0].text.strip())
145 # yields
146 -# 'The weather in Dallas, TX is 85 degrees fahrenheit. '
146 +# 'The weather in Dallas, TX is 85 degrees Fahrenheit. '
147 # 'It is partly cloudly, with highs in the 90's.'
vllm/attention/backends/mla/common.py
+1 -1
@@ -1052,7 +1052,7 @@ class MLACommonImpl(MLAAttentionImpl[T], Generic[T]):
1052 return layer.weight
1053
1054 # we currently do not have quantized bmm's which are needed for
1055 - # `W_UV` and `W_UK_T`, we we just store fp16/bf16 copies and perform
1055 + # `W_UV` and `W_UK_T`, we just store fp16/bf16 copies and perform
1056 # the bmm's in 16-bit, the extra memory overhead of this is fairly low
1057 kv_b_proj_weight = get_and_maybe_dequant_weights(self.kv_b_proj).T
1058 assert kv_b_proj_weight.shape == (
vllm/config/__init__.py
+1 -1
@@ -1169,7 +1169,7 @@ class ModelConfig:
1169 ]
1170 # Any custom overrides will be in quantization_methods so we place
1171 # them at the start of the list so custom overrides have preference
1172 - # over the built in ones.
1172 + # over the built-in ones.
1173 quantization_methods = quantization_methods + overrides
1174
1175 # Detect which checkpoint is it
vllm/distributed/kv_transfer/kv_connector/v1/nixl_connector.py
+1 -1
@@ -770,7 +770,7 @@ class NixlConnectorWorker:
770 # with joint KV for each block. This minimizes the overhead in
771 # registerMem allowing faster descs queries. In order to be able to
772 # split on kv_heads dim as required by heterogeneous TP, one must
773 - # be able to index K/V separately. Hence the we double the number
773 + # be able to index K/V separately. Hence we double the number
774 # of 'virtual' regions here and halve `block_len` below.
775 self.num_regions *= 2
776
vllm/engine/arg_utils.py
+1 -1
@@ -1159,7 +1159,7 @@ class EngineArgs:
1159 # Note(hc): In the current implementation of decode context
1160 # parallel(DCP), tp_size needs to be divisible by dcp_size,
1161 # because the world size does not change by dcp, it simply
1162 - # reuse the GPUs of TP group, and split one TP group into
1162 + # reuses the GPUs of TP group, and split one TP group into
1163 # tp_size//dcp_size DCP groups.
1164 assert self.tensor_parallel_size % self.decode_context_parallel_size \
1165 == 0, (
vllm/engine/multiprocessing/client.py
+1 -1
@@ -235,7 +235,7 @@ class MQLLMEngineClient(EngineClient):
235 # therefore we have to inform that the current
236 # processed requests failed as well. Send back a dead
237 # engine error give this feedback and also give a
238 - # 'hint' to the server to shutdown next.
238 + # 'hint' to the server to shut down next.
239 exception = self.dead_error
240
241 if request_id is None:
vllm/entrypoints/openai/cli_args.py
+1 -1
@@ -204,7 +204,7 @@ schema. Example: `[{"type": "text", "text": "Hello world!"}]`"""
204 frontend_kwargs["lora_modules"]["type"] = optional_type(str)
205 frontend_kwargs["lora_modules"]["action"] = LoRAParserAction
206
207 - # Special case: Middleware needs append action
207 + # Special case: Middleware needs to append action
208 frontend_kwargs["middleware"]["action"] = "append"
209 frontend_kwargs["middleware"]["type"] = str
210 if "nargs" in frontend_kwargs["middleware"]:
vllm/entrypoints/openai/tool_parsers/llama4_pythonic_tool_parser.py
+1 -1
@@ -176,7 +176,7 @@ class Llama4PythonicToolParser(ToolParser):
176 index] += delta.function.arguments
177
178 # HACK: serving_chat.py inspects the internal state of tool parsers
179 - # when determining it's final streaming delta, automatically
179 + # when determining its final streaming delta, automatically
180 # adding autocompleted JSON.
181 # These two lines avoid that nonsense while ensuring finish_reason
182 # is set to tool_calls when at least one tool is called.
vllm/entrypoints/openai/tool_parsers/mistral_tool_parser.py
+1 -1
@@ -143,7 +143,7 @@ class MistralToolParser(ToolParser):
143 except json.JSONDecodeError:
144 # use a regex to find the part corresponding to the tool call.
145 # NOTE: This use case should not happen if the model is trained
146 - # correctly. It's a easy possible fix so it's included, but
146 + # correctly. It's an easy possible fix so it's included, but
147 # can be brittle for very complex / highly nested tool calls
148 raw_tool_call = self.tool_call_regex.findall(tool_content)[0]
149 function_call_arr = json.loads(raw_tool_call)
vllm/model_executor/layers/fused_moe/modular_kernel.py
+1 -1
@@ -302,7 +302,7 @@ class FusedMoEPrepareAndFinalize(ABC):
302 def max_num_tokens_per_rank(self) -> Optional[int]:
303 """
304 Some PrepareFinalize All2All implementations are batched. Meaning,
305 - they can processes only as set of tokens at a time. This
305 + they can process only as set of tokens at a time. This
306 function returns the batch size i.e the maximum number of tokens
307 the implementation can process at a time.
308 Return None if there are no such restrictions.
vllm/model_executor/layers/quantization/utils/marlin_utils.py
+1 -1
@@ -201,7 +201,7 @@ def marlin_make_workspace(output_size_per_partition: int,
201 def marlin_make_workspace_new(device: torch.device,
202 max_blocks_per_sm: int = 1) -> torch.Tensor:
203 # In the new marlin kernel, we use the num of threadblocks as workspace
204 - # size. The num of threadblocks is is sms_count * max_blocks_per_sm.
204 + # size. The num of threadblocks is sms_count * max_blocks_per_sm.
205 sms = torch.cuda.get_device_properties(device).multi_processor_count
206 return torch.zeros(sms * max_blocks_per_sm,
207 dtype=torch.int,
vllm/v1/worker/block_table.py
+1 -1
@@ -98,7 +98,7 @@ class BlockTable:
98 # here because M (max_model_len) is not necessarily divisible by
99 # block_size.
100 if self.dcp_world_size > 1:
101 - # Note(hc): The DCP implement store kvcache with a interleave
101 + # Note(hc): The DCP implement store kvcache with an interleave
102 # style, the kvcache for the token whose token_idx is i is
103 # always stored on the GPU whose dcp_rank equals i % cp_world_size:
104