Text Generation
Transformers
Safetensors
Chinese
English
deepseek_v3
vLLM
GPTQ
conversational
custom_code
text-generation-inference
4-bit precision
awq
Instructions to use QuantTrio/DeepSeek-V3.1-AWQ with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use QuantTrio/DeepSeek-V3.1-AWQ with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="QuantTrio/DeepSeek-V3.1-AWQ", trust_remote_code=True) messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("QuantTrio/DeepSeek-V3.1-AWQ", trust_remote_code=True) model = AutoModelForCausalLM.from_pretrained("QuantTrio/DeepSeek-V3.1-AWQ", trust_remote_code=True, 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=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use QuantTrio/DeepSeek-V3.1-AWQ with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "QuantTrio/DeepSeek-V3.1-AWQ" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "QuantTrio/DeepSeek-V3.1-AWQ", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/QuantTrio/DeepSeek-V3.1-AWQ
- SGLang
How to use QuantTrio/DeepSeek-V3.1-AWQ 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 "QuantTrio/DeepSeek-V3.1-AWQ" \ --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": "QuantTrio/DeepSeek-V3.1-AWQ", "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 "QuantTrio/DeepSeek-V3.1-AWQ" \ --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": "QuantTrio/DeepSeek-V3.1-AWQ", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use QuantTrio/DeepSeek-V3.1-AWQ with Docker Model Runner:
docker model run hf.co/QuantTrio/DeepSeek-V3.1-AWQ
Commit History
-
Fix chat_template crash when assistant message omits the `content` key (#5)
- Fix chat_template crash when assistant message omits the `content` key (4990745e8bd45991d7f466a1e8efa4bc62d8e837) Co-authored-by: Quentin Gallouédec <qgallouedec@users.noreply.huggingface.co>0fdeb8b
-
new installation instuction for stable/correct performance
Verified signature4e7ab3e -
patch e_score_correction_bias fp32 for vllm==0.9.2
Verified signaturee3ac9c8 -
update awq_marlin.py for vllm==0.9.2
Verified signature15fbe96
-
Update README.md
Verified signaturemove-up installation instructionc8d6023 -
Delete .ipynb_checkpoints/README-checkpoint.md
Verified signature850ce88 -
Fix wrong patch path
Verified signaturece3704b
-
Upload model-00013-of-00134.safetensors with huggingface_hub
Verified signature0ab5227 -
Upload model-00012-of-00134.safetensors with huggingface_hub
Verified signaturef2204bd -
Upload model-00015-of-00134.safetensors with huggingface_hub
Verified signaturef21b9c6 -
Upload model-00016-of-00134.safetensors with huggingface_hub
Verified signature97450a1 -
Upload model-00017-of-00134.safetensors with huggingface_hub
Verified signaturedb4ecbd -
Upload model-00134-of-00134.safetensors with huggingface_hub
Verified signature4e257f0 -
Upload model-00132-of-00134.safetensors with huggingface_hub
Verified signaturee0c01c5 -
Upload model-00131-of-00134.safetensors with huggingface_hub
Verified signature3b1c606 -
Upload model-00133-of-00134.safetensors with huggingface_hub
Verified signature135b505 -
Upload model-00130-of-00134.safetensors with huggingface_hub
Verified signature6e4c850 -
Upload model-00129-of-00134.safetensors with huggingface_hub
Verified signature2292c52 -
Upload model-00127-of-00134.safetensors with huggingface_hub
Verified signaturee0f4f2c -
Upload model-00128-of-00134.safetensors with huggingface_hub
Verified signature0ebc8b2 -
Upload model-00126-of-00134.safetensors with huggingface_hub
Verified signaturece59353 -
Upload model-00125-of-00134.safetensors with huggingface_hub
Verified signaturef960316 -
Upload model-00124-of-00134.safetensors with huggingface_hub
Verified signature3c20386 -
Upload model-00123-of-00134.safetensors with huggingface_hub
Verified signature881626a -
Upload model-00122-of-00134.safetensors with huggingface_hub
Verified signature104ea53 -
Upload model-00121-of-00134.safetensors with huggingface_hub
Verified signature524fd95 -
Upload model-00119-of-00134.safetensors with huggingface_hub
Verified signature755ab30 -
Upload model-00120-of-00134.safetensors with huggingface_hub
Verified signature070fbd3 -
Upload model-00118-of-00134.safetensors with huggingface_hub
Verified signaturea668a7b -
Upload model-00114-of-00134.safetensors with huggingface_hub
Verified signatureb6e8206 -
Upload model-00115-of-00134.safetensors with huggingface_hub
Verified signaturec098148 -
Upload model-00117-of-00134.safetensors with huggingface_hub
Verified signatured58e435 -
Upload model-00116-of-00134.safetensors with huggingface_hub
Verified signature5e88991 -
Upload model-00113-of-00134.safetensors with huggingface_hub
Verified signature52a7af3 -
Upload model-00111-of-00134.safetensors with huggingface_hub
Verified signatured3671b8 -
Upload model-00112-of-00134.safetensors with huggingface_hub
Verified signaturee09360d -
Upload model-00110-of-00134.safetensors with huggingface_hub
Verified signaturee612072 -
Upload model-00109-of-00134.safetensors with huggingface_hub
Verified signature4de1c67 -
Upload model-00108-of-00134.safetensors with huggingface_hub
Verified signature1424d9f -
Upload model-00107-of-00134.safetensors with huggingface_hub
Verified signature3b07a07 -
Upload model-00106-of-00134.safetensors with huggingface_hub
Verified signature905a32a -
Upload model-00104-of-00134.safetensors with huggingface_hub
Verified signature0ce029c -
Upload model-00103-of-00134.safetensors with huggingface_hub
Verified signature8f5f0d8 -
Upload model-00105-of-00134.safetensors with huggingface_hub
Verified signature37a9ead -
Upload model-00102-of-00134.safetensors with huggingface_hub
Verified signature6647226 -
Upload model-00101-of-00134.safetensors with huggingface_hub
Verified signatured2a02d5 -
Upload model-00100-of-00134.safetensors with huggingface_hub
Verified signature4fa32d4 -
Upload model-00099-of-00134.safetensors with huggingface_hub
Verified signature908a078 -
Upload model-00098-of-00134.safetensors with huggingface_hub
Verified signature261d6f2 -
Upload model-00097-of-00134.safetensors with huggingface_hub
Verified signature2ae971a