Repository navigation
📝 [NPU] Use vendor-neutral wording in quantization comments - #36768
Merged
sglang-npu-bot merged 2 commits intoAug 29, 2026
Merged
sglang-npu-bot merged 2 commits into
sglang-npu-bot merged 2 commits into
Conversation
Follow-up to sgl-project#34829, which cleaned the MXFP8/MXFP4 linear methods but left comments in five other files that name external projects. - srt MoE MXFP8: the init-routing scale-normalisation docstring, the fused-MoE weight-layout note and the Qwen3 MoE router-gate note (sgl-project#30768). - srt dual-level MXFP4: the NPUDualLevelMXFP4LinearMethod docstring (sgl-project#23795). - multimodal_gen MXFP4: the offline ModelSlim scheme and the online diffusion method (sgl-project#22338). Every removed line was pure attribution; the surrounding comments already state the layout, format and calibration requirements they were pointing at. Where a reference carried real information (the online MXFP4 weight path being experimental because the established path is offline-only), the fact is kept and only the project name dropped. Comment-only change; no behaviour change.
TallMessiWu
requested review from
Alisehen,
HaiShaw,
OrangeRedeng,
iforgetmyname,
ping1jing2 and
whybeyoung
as code owners
August 28, 2026 02:37
Comment/docstring only: replace the Ascend brand wording with NPU in the SRT and Diffusion quantization modules. Identifiers (AscendQuantInfo, MoeRunnerBackend.ASCEND, ascend_tp/ascend_fuseep, the ascend attention backend) and runtime error strings are left untouched.
ping1jing2
approved these changes
Aug 29, 2026
Collaborator
|
i merged it without running CI as there is no code change in this PR |
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.
Motivation
Follow-up to #34829. That PR cleaned the MXFP8/MXFP4 linear methods, but the
NPU quantization comments still carried two kinds of vendor wording, all landed
by my earlier NPU quantization PRs:
Ascendused as prose branding in docstrings for modules that are otherwisenamed and namespaced
npu.Modifications
Comment-only cleanup, no code touched.
Third-party references removed:
srt/hardware_backend/npu/moe/init_routing.py,.../quantization/moe_methods.py,srt/models/qwen3_moe.py— the MXFP8 MoE scale-normalisation docstring, thefused-MoE weight-layout note and the Qwen3 MoE router-gate note (from ✨ [llm][npu][quant] Add W8A8 MXFP8 quantization for Qwen3 MoE on Ascend NPU #30768).
srt/hardware_backend/npu/quantization/linear_method_npu.py— theNPUDualLevelMXFP4LinearMethoddocstring (from ✨ [llm][npu][quant] Add W4A4 MXFP4 quantization support for Qwen3 Dense on Ascend NPU #23795).multimodal_gen/runtime/layers/quantization/modelslim_mxfp4_scheme.pyandmxfp4_npu.py— the offline ModelSlim MXFP4 scheme and the online diffusionMXFP4 method (from ✨ [diffusion][npu][quant] Add MXFP4 quantization support for Wan2.2 Diffusion on Ascend NPU #22338).
Every removed line was pure attribution: the surrounding comments already state
the layout, format and calibration requirements those references pointed at
(FRACTAL_NZ format 29, the
[in/level0_block_size, out]L0 scale transpose, thesmooth-quant
mul_scalerequirement, the strided transpose views). Where areference carried real information — the online MXFP4 diffusion weight path being
experimental because the established path is offline-only — the fact is kept and
only the project name dropped.
Ascendprose reworded toNPU:linear_method_npu.py— six class docstring headers, plus the three hardwarerequirement lines (
Ascend 950 (A5)→A5 NPU; the file already uses the bareA5/A2/A3shorthand elsewhere).moe_methods.py— the two dispatcher dtype notes and theNPUMXFP8MoEMethodheader.
online_moe_methods.py,modelslim_mxfp4_scheme.py,modelslim_mxfp8_scheme.py,mxfp4_npu.py— module and class docstring headers.Identifiers are deliberately untouched, since they are real API names and CLI
values:
AscendQuantInfo,AscendRunnerCore,MoeRunnerBackend.ASCEND,is_ascend_fuseep(),ascend_tp/ascend_fuseep, and theascendattentionbackend. The two runtime error strings that name the hardware are also left as
they are, so user-facing messages do not change.
Accuracy Tests
Not applicable — comments only, no behaviour change.
python -m black --checkand an AST parse pass on all eight files.
Speed Tests and Profiling
Not applicable — comments only.
Checklist
CI States
Latest PR Test (Base): ❌ Run #33155197134
Latest PR Test (Extra): ❌ Run #33155196857
Latest PR Test (AMD ROCm 7.2): ❌ Run #33155196931