Instructions to use zjunlp/zhixi-13b-diff with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use zjunlp/zhixi-13b-diff with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="zjunlp/zhixi-13b-diff")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("zjunlp/zhixi-13b-diff") model = AutoModelForCausalLM.from_pretrained("zjunlp/zhixi-13b-diff", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use zjunlp/zhixi-13b-diff with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "zjunlp/zhixi-13b-diff" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "zjunlp/zhixi-13b-diff", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/zjunlp/zhixi-13b-diff
- SGLang
How to use zjunlp/zhixi-13b-diff 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 "zjunlp/zhixi-13b-diff" \ --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": "zjunlp/zhixi-13b-diff", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "zjunlp/zhixi-13b-diff" \ --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": "zjunlp/zhixi-13b-diff", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use zjunlp/zhixi-13b-diff with Docker Model Runner:
docker model run hf.co/zjunlp/zhixi-13b-diff
Commit History
-
Adding `safetensors` variant of this model
Verified signatureThis is an automated PR created with https://huggingface.co/spaces/safetensors/convert This new file is equivalent to `pytorch_model.bin` but safe in the sense that no arbitrary code can be put into it. These files also happen to load much faster than their pytorch counterpart: https://colab.research.google.com/github/huggingface/notebooks/blob/main/safetensors_doc/en/speed.ipynb The widgets on your model page will run using this model even if this is not merged making sure the file actually works. If you find any issues: please report here: https://huggingface.co/spaces/safetensors/convert/discussions Feel free to ignore this PR.34eab8b
-
Update README.md
6c3aaf3
-
Update README.md
0f812a1
-
Update README.md
71e6977 -
Update README.md
ced6ff7 -
Update README.md
a4f5093 -
Update README.md
74a41f0 -
Update README.md
9d1dff5 -
Update README.md
353b4d8 -
Update README.md
ff931de -
Update README.md
c808e0b -
Update README.md
c30ffa3
-
Upload zhixi_logo.png
3e83f2b
-
Update README.md
5edb68d
-
Update README.md
c07e1c0 -
Update README.md
47fe80d -
Update README.md
f5606e7 -
Create README.md
0eceb86 -
Upload pytorch_model.bin.index.json with huggingface_hub
ee257c6
-
Upload special_tokens_map.json with huggingface_hub
215a66b -
Upload tokenizer_config.json with huggingface_hub
58a8e42 -
Upload tokenizer.model with huggingface_hub
42da2c7 -
Upload generation_config.json with huggingface_hub
3120db9 -
Upload config.json with huggingface_hub
e0608af
-
Upload pytorch_model-00006-of-00006.bin with huggingface_hub
05cdb69 -
Upload pytorch_model-00005-of-00006.bin with huggingface_hub
970ba4a -
Upload pytorch_model-00004-of-00006.bin with huggingface_hub
3ac72f5 -
Upload pytorch_model-00003-of-00006.bin with huggingface_hub
d2be6ce -
Upload pytorch_model-00002-of-00006.bin with huggingface_hub
240f2a8 -
Upload pytorch_model-00001-of-00006.bin with huggingface_hub
40aeb13 -
initial commit
17b2258