Text Generation
Transformers
Safetensors
English
qwen2
chat
conversational
Eval Results
text-generation-inference
Instructions to use Qwen/QwQ-32B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Qwen/QwQ-32B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Qwen/QwQ-32B") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Qwen/QwQ-32B") model = AutoModelForCausalLM.from_pretrained("Qwen/QwQ-32B", 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]:])) - Inference
- Notebooks
- Google Colab
- Kaggle
- AMD Developer Cloud
- Local Apps Settings
- vLLM
How to use Qwen/QwQ-32B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Qwen/QwQ-32B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Qwen/QwQ-32B", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Qwen/QwQ-32B
- SGLang
How to use Qwen/QwQ-32B 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 "Qwen/QwQ-32B" \ --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": "Qwen/QwQ-32B", "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 "Qwen/QwQ-32B" \ --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": "Qwen/QwQ-32B", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Qwen/QwQ-32B with Docker Model Runner:
docker model run hf.co/Qwen/QwQ-32B
remove part about long context modifications
#32 opened over 1 year ago
by
nbroad
add a reasoning effort option
2
#31 opened over 1 year ago
by
TheBigBlockPC
用vllm时应该是什么参数
6
#30 opened over 1 year ago
by
daiwk
遇到复杂问题时,开始推理时有<think>,推理结束了还没有</think>
7
#29 opened over 1 year ago
by
digits12
Is this model native 128K context length, or YaRN extended?
7
#28 opened over 1 year ago
by
danielhanchen
docs: update README.md
#27 opened over 1 year ago
by
eltociear
Thanks a lot for sharing this model!
❤️ 5
#26 opened over 1 year ago
by
FalconNet
Doesn't Generate `<think>` tags
3
#25 opened over 1 year ago
by
bingw5
【乱码问题】输入约1w长度,输出超过1000长度,结尾部分会乱码。稳定复现!
1
#24 opened over 1 year ago
by
chizhu
是否需要添加系统prompt
1
#23 opened over 1 year ago
by
wphtrying
A pure C++ high-performance OpenAI LLM service powered by TensorRT-LLM and GRPS, with support for QWQ.
#22 opened over 1 year ago
by
zhaocc1106
复杂推理进入死循环
30
#21 opened over 1 year ago
by
frankgxy
I've tried it, the locally deployed 8G4060 can run, it's just a bit slower.
➕👍 7
2
#20 opened over 1 year ago
by
Alta007
Off the charts - GREAT JOB!
1
#17 opened over 1 year ago
by
DavidAU
Where can I see the GPQA for this model?
1
#16 opened over 1 year ago
by
capgrey
issue of "think too much" ,how to?(chinese)
2
#14 opened over 1 year ago
by
fenglui
Local Installation Video - Step-by-Step Tutorial
🔥 5
#13 opened over 1 year ago
by
fahdmirzac
Tool-Calling Format
🚀 1
1
#12 opened over 1 year ago
by
G-reen
我的3090TI 24GB显存运行非常愉快!感谢开发团队!
👍🚀 14
6
#11 opened over 1 year ago
by
ubergarm
add missing special tokens in tokenizer.json
➕ 3
#10 opened over 1 year ago
by
mmoskal
Is `rms_norm_eps` 1e-5 or 1e-6
#9 opened over 1 year ago
by
danielhanchen
Oh My NVDA Position
🔥🤯 3
1
#8 opened over 1 year ago
by
Eric2i
What languages were you trained in?
👍 1
2
#7 opened over 1 year ago
by
NickyNicky
You guys are the pioneers!
#6 opened over 1 year ago
by
owao
missing opening <think>
20
#4 opened over 1 year ago
by
chriswritescode
One Of Many
🔥 2
#3 opened over 1 year ago
by
nanowell
Is system prompt required?
👍 1
1
#2 opened over 1 year ago
by
baohao