Instructions to use tensorblock/Yi-Coder-9B-Chat-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="tensorblock/Yi-Coder-9B-Chat-GGUF") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("tensorblock/Yi-Coder-9B-Chat-GGUF", dtype="auto") - llama-cpp-python
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="tensorblock/Yi-Coder-9B-Chat-GGUF", filename="Yi-Coder-9B-Chat-Q2_K.gguf", )
llm.create_chat_completion( messages = [ { "role": "user", "content": "What is the capital of France?" } ] ) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K # Run inference directly in the terminal: llama-cli -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K # Run inference directly in the terminal: llama-cli -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K # Run inference directly in the terminal: ./llama-cli -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K # Run inference directly in the terminal: ./build/bin/llama-cli -hf tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
Use Docker
docker model run hf.co/tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
- LM Studio
- Jan
- vLLM
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "tensorblock/Yi-Coder-9B-Chat-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "tensorblock/Yi-Coder-9B-Chat-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
- SGLang
How to use tensorblock/Yi-Coder-9B-Chat-GGUF 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 "tensorblock/Yi-Coder-9B-Chat-GGUF" \ --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": "tensorblock/Yi-Coder-9B-Chat-GGUF", "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 "tensorblock/Yi-Coder-9B-Chat-GGUF" \ --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": "tensorblock/Yi-Coder-9B-Chat-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with Ollama:
ollama run hf.co/tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
- Unsloth Studio
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for tensorblock/Yi-Coder-9B-Chat-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for tensorblock/Yi-Coder-9B-Chat-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for tensorblock/Yi-Coder-9B-Chat-GGUF to start chatting
- Docker Model Runner
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with Docker Model Runner:
docker model run hf.co/tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
- Lemonade
How to use tensorblock/Yi-Coder-9B-Chat-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull tensorblock/Yi-Coder-9B-Chat-GGUF:Q2_K
Run and chat with the model
lemonade run user.Yi-Coder-9B-Chat-GGUF-Q2_K
List all available models
lemonade list
Keep Q2_K/Q3_K_M gguf only
Browse files- Yi-Coder-9B-Chat-Q3_K_L.gguf +0 -3
- Yi-Coder-9B-Chat-Q3_K_S.gguf +0 -3
- Yi-Coder-9B-Chat-Q4_0.gguf +0 -3
- Yi-Coder-9B-Chat-Q4_K_M.gguf +0 -3
- Yi-Coder-9B-Chat-Q4_K_S.gguf +0 -3
- Yi-Coder-9B-Chat-Q5_0.gguf +0 -3
- Yi-Coder-9B-Chat-Q5_K_M.gguf +0 -3
- Yi-Coder-9B-Chat-Q5_K_S.gguf +0 -3
- Yi-Coder-9B-Chat-Q6_K.gguf +0 -3
- Yi-Coder-9B-Chat-Q8_0.gguf +0 -3
Yi-Coder-9B-Chat-Q3_K_L.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:e4aae7ced0c53e2da74a28e0742522b03b68e5a8f229f2237ac11d2a6ad4b491
|
| 3 |
-
size 4690752352
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q3_K_S.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:59ea285649c3ac3df6d7eb1ae5f0de7725d7966b455c284380db43ee437793cd
|
| 3 |
-
size 3899208544
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q4_0.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:3422932540dcf0b3003d18a6fbc12828cfbc1944092ed6d8a3cd6f03dac3bd8f
|
| 3 |
-
size 5036995424
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q4_K_M.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:08615c85ba122e3eb444961b62c4c4c5c222710fc36b4ff9330662fb90dc6cd2
|
| 3 |
-
size 5328958304
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q4_K_S.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:6a43b9199a683069f76a2fd41fdfe42978ed12ade50c87b02d842142abe192ae
|
| 3 |
-
size 5071860576
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q5_0.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:2d00934c8f21291142af09a1e5750e8e5fe9805a76c39c01844227d128d28457
|
| 3 |
-
size 6107853664
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q5_K_M.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:f281212c86cb02ed595cc525ada1a991e89297585a21890bb52d0af1c92f4254
|
| 3 |
-
size 6258258784
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q5_K_S.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:17086142eaa417853b23665731f21c17193edaaf1819efb46713de97ce3c828f
|
| 3 |
-
size 6107853664
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q6_K.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:0065d20902dd6fb5d064b66c9a180a13709a86efd7f4b2f1540040ff34ab5ca5
|
| 3 |
-
size 7245640544
|
|
|
|
|
|
|
|
|
|
|
|
Yi-Coder-9B-Chat-Q8_0.gguf
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:31750cc50cc0f73e2a3f3a917b0b906e6dee5c325ecf506c37d2bd38d8afd2ff
|
| 3 |
-
size 9383916384
|
|
|
|
|
|
|
|
|
|
|
|