Skip to content

[Quant] Support MXFP4 W4A16 for compressed-tensors MoE models #138

Closed
dsikka wants to merge 122 commits intomxfp4-w4a16-ct-densefrom
mxfp4-w4a16-ct-moe
Closed

[Quant] Support MXFP4 W4A16 for compressed-tensors MoE models #138
dsikka wants to merge 122 commits intomxfp4-w4a16-ct-densefrom
mxfp4-w4a16-ct-moe

Conversation

@dsikka
Copy link

@dsikka dsikka commented Jan 9, 2026

Purpose

Follow-up to: vllm-project#31926
Add MoE support for MXFP4 CT Models. Currently only supporting weight-only quantization through the marlin integration.

There's a ton of shared boilerplate code between mxfp4 and nvfp4 that we should consider combining.

Test Plan

Qwen3 MoE MXFP4A16: https://huggingface.co/nm-testing/Qwen3-30B-A3B-MXFP4A16/tree/main

Test Result

Running GSM8K evaluation: 1319 questions, 5-shot
Evaluating: 100%|█████████████████████████████| 1319/1319 [00:29<00:00, 45.47it/s]

Results:
Accuracy: 0.882
Invalid responses: 0.000
Total latency: 29.023 s
Questions per second: 45.446
Total output tokens: 156720
Output tokens per second: 5399.780

Essential Elements of an Effective PR Description Checklist
  • The purpose of the PR, such as "Fix some issue (link existing issues this PR will resolve)".
  • The test plan, such as providing test command.
  • The test results, such as pasting the results comparison before and after, or e2e results
  • (Optional) The necessary documentation update, such as updating supported_models.md and examples for a new model.
  • (Optional) Release notes update. If your change is user facing, please update the release notes draft in the Google Doc.

jeremyteboul and others added 10 commits January 9, 2026 19:34
Signed-off-by: Jeremy Teboul <jeremyte@meta.com>
…ject#29354)

Signed-off-by: Runkai Tao <rt572@physics.rutgers.edu>
Co-authored-by: Jee Jee Li <pandaleefree@gmail.com>
Signed-off-by: jiahanc <173873397+jiahanc@users.noreply.github.com>
Signed-off-by: Lucas Wilkinson <lwilkins@redhat.com>
…llm-project#31836)

Signed-off-by: Andrew Xia <axia@fb.com>
Co-authored-by: Andrew Xia <axia@fb.com>
Signed-off-by: Matthew Bonanni <mbonanni@redhat.com>
…-project#31336)

Signed-off-by: izhuhaoran <izhuhaoran@qq.com>
Signed-off-by: zhuhaoran <zhuhaoran.zhr@alibaba-inc.com>

self.moe_quant_config = self.get_fused_moe_quant_config(layer)
if self.moe_quant_config is not None:
self.kernel = make_nvfp4_moe_kernel(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This works because Marlin autodetects mxfp4?

MatthewBonanni and others added 15 commits January 10, 2026 00:27
Signed-off-by: Matthew Bonanni <mbonanni@redhat.com>
Signed-off-by: Russell Bryant <rbryant@redhat.com>
)

Signed-off-by: Micah Williamson <micah.williamson@amd.com>
…t#31616)

Signed-off-by: c0de128 <kevin.mckay@outlook.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Cyrus Leung <tlleungac@connect.ust.hk>
Signed-off-by: Andy Xie <andy.xning@gmail.com>
Signed-off-by: Lucas Kabela <lucaskabela@meta.com>
Signed-off-by: Roger Wang <hey@rogerw.io>
Co-authored-by: Roger Wang <hey@rogerw.io>
Signed-off-by: Patryk Saffer <patryk.saffer99@gmail.com>
Signed-off-by: PatrykSaffer <patryk.saffer@mistral.ai>
Co-authored-by: Patryk Saffer <patryk.saffer99@gmail.com>
Co-authored-by: Luka Govedič <ProExpertProg@users.noreply.github.com>
Co-authored-by: Michael Goin <mgoin64@gmail.com>
…rocess (vllm-project#31295)

Signed-off-by: c0de128 <kevin.mckay@outlook.com>
)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
…chema test examples (vllm-project#32063)

Signed-off-by: Andreas Karatzas <akaratza@amd.com>
AndreasKaratzas and others added 22 commits January 12, 2026 22:33
…vision encoder (vllm-project#32233)

Signed-off-by: Andreas Karatzas <akaratza@amd.com>
Signed-off-by: Xingyu Liu <charlotteliu12x@gmail.com>
Signed-off-by: esmeetu <jasonailu87@gmail.com>
vllm-project#32126)

Signed-off-by: YunzhuLu <lucia.yunzhu@gmail.com>
Co-authored-by: Isotr0py <mozf@mail2.sysu.edu.cn>
Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
…m-project#32243)

Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
…ct#32198)

Signed-off-by: NickLucche <nlucches@redhat.com>
…ject#29867)

Signed-off-by: Mickael Seznec <mickael@mistral.ai>
Signed-off-by: Michael Goin <mgoin64@gmail.com>
Co-authored-by: Robert Shaw <114415538+robertgshaw2-redhat@users.noreply.github.com>
Co-authored-by: Michael Goin <mgoin64@gmail.com>
…architecture (vllm-project#32240)

Signed-off-by: chaunceyjiang <chaunceyjiang@gmail.com>
…ct#32215)

Signed-off-by: Matthew Bonanni <mbonanni@redhat.com>
Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
…ect#32169)

Signed-off-by: Martin Hickey <martin.hickey@ie.ibm.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
…ory leak (vllm-project#32181)

Signed-off-by: Mathis Felardos <mathis@mistral.ai>
Signed-off-by: Matthew Bonanni <mbonanni@redhat.com>
Co-authored-by: Luka Govedič <ProExpertProg@users.noreply.github.com>
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
…-project#32050)

Signed-off-by: Sage Moore <sage@neuralmagic.com>
Signed-off-by: Andrew Xia <axia@fb.com>
Signed-off-by: Andrew Xia <mitandrewxia@gmail.com>
Signed-off-by: Lu Fang <30275821+houseroad@users.noreply.github.com>
Co-authored-by: Andrew Xia <axia@fb.com>
Co-authored-by: Lu Fang <30275821+houseroad@users.noreply.github.com>
Signed-off-by: Dmitry Tokarev <dtokarev@nvidia.com>
Signed-off-by: Dipika Sikka <dipikasikka1@gmail.com>
@dsikka dsikka force-pushed the mxfp4-w4a16-ct-moe branch from eec67ec to af677f5 Compare January 13, 2026 19:51
@dsikka dsikka closed this Jan 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.