mit-han-lab/svdquant-datasets
Preview • Updated • 214 • 6
How to use mit-han-lab/nunchaku-t5 with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="mit-han-lab/nunchaku-t5") # Load model directly
from transformers import AutoModel
model = AutoModel.from_pretrained("mit-han-lab/nunchaku-t5", dtype="auto")How to use mit-han-lab/nunchaku-t5 with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "mit-han-lab/nunchaku-t5"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "mit-han-lab/nunchaku-t5",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/mit-han-lab/nunchaku-t5
How to use mit-han-lab/nunchaku-t5 with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "mit-han-lab/nunchaku-t5" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "mit-han-lab/nunchaku-t5",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'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 "mit-han-lab/nunchaku-t5" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "mit-han-lab/nunchaku-t5",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use mit-han-lab/nunchaku-t5 with Docker Model Runner:
docker model run hf.co/mit-han-lab/nunchaku-t5
This repository has been migrated to https://huggingface.co/nunchaku-tech/nunchaku-t5 and will be hidden in December 2025.
This repository contains Nunchaku-quantized versions of T5-XXL, used to encode text prompt to the embeddings. It is used to reduce the memory footprint of the model.
awq-int4-flux.1-t5xxl.safetensors: AWQ quantized W4A16 T5-XXL model for FLUX.1.@inproceedings{
li2024svdquant,
title={SVDQuant: Absorbing Outliers by Low-Rank Components for 4-Bit Diffusion Models},
author={Li*, Muyang and Lin*, Yujun and Zhang*, Zhekai and Cai, Tianle and Li, Xiuyu and Guo, Junxian and Xie, Enze and Meng, Chenlin and Zhu, Jun-Yan and Han, Song},
booktitle={The Thirteenth International Conference on Learning Representations},
year={2025}
}
@inproceedings{
lin2023awq,
title={AWQ: Activation-aware Weight Quantization for LLM Compression and Acceleration},
author={Lin, Ji and Tang, Jiaming and Tang, Haotian and Yang, Shang and Chen, Wei-Ming and Wang, Wei-Chen and Xiao, Guangxuan and Dang, Xingyu and Gan, Chuang and Han, Song},
booktitle={MLSys},
year={2024}
}
Base model
google/t5-v1_1-xxl