Instructions to use JongYeop/Qwen3-30B-A3B-NVFP4-W4A4 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use JongYeop/Qwen3-30B-A3B-NVFP4-W4A4 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="JongYeop/Qwen3-30B-A3B-NVFP4-W4A4") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("JongYeop/Qwen3-30B-A3B-NVFP4-W4A4") model = AutoModelForCausalLM.from_pretrained("JongYeop/Qwen3-30B-A3B-NVFP4-W4A4", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use JongYeop/Qwen3-30B-A3B-NVFP4-W4A4 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "JongYeop/Qwen3-30B-A3B-NVFP4-W4A4" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "JongYeop/Qwen3-30B-A3B-NVFP4-W4A4", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/JongYeop/Qwen3-30B-A3B-NVFP4-W4A4
- SGLang
How to use JongYeop/Qwen3-30B-A3B-NVFP4-W4A4 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "JongYeop/Qwen3-30B-A3B-NVFP4-W4A4" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "JongYeop/Qwen3-30B-A3B-NVFP4-W4A4", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "JongYeop/Qwen3-30B-A3B-NVFP4-W4A4" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "JongYeop/Qwen3-30B-A3B-NVFP4-W4A4", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use JongYeop/Qwen3-30B-A3B-NVFP4-W4A4 with Docker Model Runner:
docker model run hf.co/JongYeop/Qwen3-30B-A3B-NVFP4-W4A4
Qwen3-30B-A3B-NVFP4-W4A4
Qwen/Qwen3-30B-A3B quantized to NVFP4 W4A4 (NVIDIA FP4, 4-bit weights + 4-bit activations) with llm-compressor.
This is a Mixture-of-Experts (MoE) model. The MoE router (mlp.gate) and the
lm_head are kept at full precision; the attention and expert projection layers
are quantized to NVFP4.
Quantization details
- Scheme: NVFP4 W4A4 — per-tensor global scale + per-group (size 16) FP8 (e4m3) local scales for weights, per-tensor activation scales
- Ignored layers:
lm_head, MoE router (re:.*mlp.gate$) - Calibration: 512 chat-formatted samples from
HuggingFaceH4/ultrachat_200k(train_sft), max sequence length 2048 - Tooling: llm-compressor 0.9.0, compressed-tensors 0.13.0
- Format: compressed-tensors
⚠️ Hardware / runtime support note
NVFP4 fused-MoE inference requires a runtime kernel for your GPU. The cutlass
NVFP4 grouped-GEMM MoE kernel (get_cutlass_moe_mm_data in vLLM) is currently
compiled only for CUDA compute capability 9.0 (Hopper) and 10.0
(datacenter Blackwell, B200/GB200).
On SM120 GPUs (e.g. RTX PRO 6000 Blackwell, compute capability 12.0), the
stock vLLM build used to produce this checkpoint does not yet ship a compiled
NVFP4 MoE kernel, so vLLM serving fails with
No compiled get_cutlass_moe_mm_data: ... capability 120. Required capability: 90 or 100.
This is a runtime kernel limitation, not a problem with the checkpoint — the
quantized weights were verified (correct NVFP4 packing; router and lm_head left
in full precision). To serve this model, use a GPU/kernel combination that
provides an NVFP4 fused-MoE kernel (Hopper or B200), or a vLLM build with NVFP4
MoE kernels compiled for your architecture.
Usage (vLLM, on supported hardware)
from vllm import LLM, SamplingParams
llm = LLM(model="JongYeop/Qwen3-30B-A3B-NVFP4-W4A4")
out = llm.generate(
["Explain mixture-of-experts in one sentence."],
SamplingParams(temperature=0.7, max_tokens=128),
)
print(out[0].outputs[0].text)
Recipe
quant_stage:
quant_modifiers:
QuantizationModifier:
ignore: ["lm_head", "re:.*mlp.gate$"]
scheme: "NVFP4"
targets: ["Linear"]
- Downloads last month
- 42