Instructions to use tensorblock/gemma-2b-coder-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use tensorblock/gemma-2b-coder-GGUF with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf tensorblock/gemma-2b-coder-GGUF:Q2_K # Run inference directly in the terminal: llama cli -hf tensorblock/gemma-2b-coder-GGUF:Q2_K
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf tensorblock/gemma-2b-coder-GGUF:Q2_K # Run inference directly in the terminal: llama cli -hf tensorblock/gemma-2b-coder-GGUF:Q2_K
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf tensorblock/gemma-2b-coder-GGUF:Q2_K # Run inference directly in the terminal: ./build/bin/llama cli -hf tensorblock/gemma-2b-coder-GGUF:Q2_K
Use Docker
docker model run hf.co/tensorblock/gemma-2b-coder-GGUF:Q2_K
- Llama new
- LM Studio
- Jan
- vLLM
How to use tensorblock/gemma-2b-coder-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "tensorblock/gemma-2b-coder-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "tensorblock/gemma-2b-coder-GGUF", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/tensorblock/gemma-2b-coder-GGUF:Q2_K
- Ollama
How to use tensorblock/gemma-2b-coder-GGUF with Ollama:
ollama run hf.co/tensorblock/gemma-2b-coder-GGUF:Q2_K
- Unsloth Desktop
- Docker Model Runner
How to use tensorblock/gemma-2b-coder-GGUF with Docker Model Runner:
docker model run hf.co/tensorblock/gemma-2b-coder-GGUF:Q2_K
- Lemonade
How to use tensorblock/gemma-2b-coder-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull tensorblock/gemma-2b-coder-GGUF:Q2_K
Run and chat with the model
lemonade run user.gemma-2b-coder-GGUF-Q2_K
List all available models
lemonade list
- Atomic Chat
Upload folder using huggingface_hub
Browse filesFiles changed (14)
- .gitattributes+12
- README.mdAdded+90
- gemma-2b-coder-Q2_K.ggufAdded+3
- gemma-2b-coder-Q3_K_L.ggufAdded+3
- gemma-2b-coder-Q3_K_M.ggufAdded+3
- gemma-2b-coder-Q3_K_S.ggufAdded+3
- gemma-2b-coder-Q4_0.ggufAdded+3
- gemma-2b-coder-Q4_K_M.ggufAdded+3
- gemma-2b-coder-Q4_K_S.ggufAdded+3
- gemma-2b-coder-Q5_0.ggufAdded+3
- gemma-2b-coder-Q5_K_M.ggufAdded+3
- gemma-2b-coder-Q5_K_S.ggufAdded+3
- gemma-2b-coder-Q6_K.ggufAdded+3
- gemma-2b-coder-Q8_0.ggufAdded+3
32 unmodified lines33343532 unmodified lines*.zip filter=lfs diff=lfs merge=lfs -text*.zst filter=lfs diff=lfs merge=lfs -text*tfevents* filter=lfs diff=lfs merge=lfs -text32 unmodified lines33343536373839404142434445464732 unmodified lines*.zip filter=lfs diff=lfs merge=lfs -text*.zst filter=lfs diff=lfs merge=lfs -text*tfevents* filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q2_K.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q3_K_L.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q3_K_M.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q3_K_S.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q4_0.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q4_K_S.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q5_0.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q5_K_M.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q5_K_S.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q6_K.gguf filter=lfs diff=lfs merge=lfs -textgemma-2b-coder-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990---tags:- generated_from_trainer- code- coding- gemma- TensorBlock- GGUFlicense_name: gemma-terms-of-uselicense_link: https://ai.google.dev/gemma/termslanguage:- codethumbnail: https://huggingface.co/mrm8488/gemma-2b-coder/resolve/main/logo.pngdatasets:- HuggingFaceH4/CodeAlpaca_20Kpipeline_tag: text-generationbase_model: MAISAAI/gemma-2b-codermodel-index:- name: gemma-2b-coder results: []---
<div style="width: auto; margin-left: auto; margin-right: auto"><img src="https://i.imgur.com/jC7kdl8.jpeg" alt="TensorBlock" style="width: 100%; min-width: 400px; display: block; margin: auto;"></div><div style="display: flex; justify-content: space-between; width: 100%;"> <div style="display: flex; flex-direction: column; align-items: flex-start;"> <p style="margin-top: 0.5em; margin-bottom: 0em;"> Feedback and support: TensorBlock's <a href="https://x.com/tensorblock_aoi">Twitter/X</a>, <a href="https://t.me/TensorBlock">Telegram Group</a> and <a href="https://x.com/tensorblock_aoi">Discord server</a> </p> </div></div>
## MAISAAI/gemma-2b-coder - GGUF
This repo contains GGUF format model files for [MAISAAI/gemma-2b-coder](https://huggingface.co/MAISAAI/gemma-2b-coder).
The files were quantized using machines provided by [TensorBlock](https://tensorblock.co/), and they are compatible with llama.cpp as of [commit b4242](https://github.com/ggerganov/llama.cpp/commit/a6744e43e80f4be6398fc7733a01642c846dce1d).
<div style="text-align: left; margin: 20px 0;"> <a href="https://tensorblock.co/waitlist/client" style="display: inline-block; padding: 10px 20px; background-color: #007bff; color: white; text-decoration: none; border-radius: 5px; font-weight: bold;"> Run them on the TensorBlock client using your local machine ↗ </a></div>
## Prompt template
```
```
## Model file specification
| Filename | Quant type | File Size | Description || -------- | ---------- | --------- | ----------- || [gemma-2b-coder-Q2_K.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q2_K.gguf) | Q2_K | 1.158 GB | smallest, significant quality loss - not recommended for most purposes || [gemma-2b-coder-Q3_K_S.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q3_K_S.gguf) | Q3_K_S | 1.288 GB | very small, high quality loss || [gemma-2b-coder-Q3_K_M.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q3_K_M.gguf) | Q3_K_M | 1.384 GB | very small, high quality loss || [gemma-2b-coder-Q3_K_L.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q3_K_L.gguf) | Q3_K_L | 1.466 GB | small, substantial quality loss || [gemma-2b-coder-Q4_0.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q4_0.gguf) | Q4_0 | 1.551 GB | legacy; small, very high quality loss - prefer using Q3_K_M || [gemma-2b-coder-Q4_K_S.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q4_K_S.gguf) | Q4_K_S | 1.560 GB | small, greater quality loss || [gemma-2b-coder-Q4_K_M.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q4_K_M.gguf) | Q4_K_M | 1.630 GB | medium, balanced quality - recommended || [gemma-2b-coder-Q5_0.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q5_0.gguf) | Q5_0 | 1.799 GB | legacy; medium, balanced quality - prefer using Q4_K_M || [gemma-2b-coder-Q5_K_S.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q5_K_S.gguf) | Q5_K_S | 1.799 GB | large, low quality loss - recommended || [gemma-2b-coder-Q5_K_M.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q5_K_M.gguf) | Q5_K_M | 1.840 GB | large, very low quality loss - recommended || [gemma-2b-coder-Q6_K.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q6_K.gguf) | Q6_K | 2.062 GB | very large, extremely low quality loss || [gemma-2b-coder-Q8_0.gguf](https://huggingface.co/tensorblock/gemma-2b-coder-GGUF/blob/main/gemma-2b-coder-Q8_0.gguf) | Q8_0 | 2.669 GB | very large, extremely low quality loss - not recommended |
## Downloading instruction
### Command line
Firstly, install Huggingface Client
```shellpip install -U "huggingface_hub[cli]"```
Then, downoad the individual model file the a local directory
```shellhuggingface-cli download tensorblock/gemma-2b-coder-GGUF --include "gemma-2b-coder-Q2_K.gguf" --local-dir MY_LOCAL_DIR```
If you wanna download multiple model files with a pattern (e.g., `*Q4_K*gguf`), you can try:
```shellhuggingface-cli download tensorblock/gemma-2b-coder-GGUF --local-dir MY_LOCAL_DIR --local-dir-use-symlinks False --include='*Q4_K*gguf'```123version https://git-lfs.github.com/spec/v1oid sha256:119b6d8a5af32f503accf3d9cdb105d4bd33fa9955a2ac9dd3244eae4043c4e2size 1157924864123version https://git-lfs.github.com/spec/v1oid sha256:26c3ca4437c9a1cace83d89ad91666ca630c383549677ad370361abb779d1a21size 1465591808123version https://git-lfs.github.com/spec/v1oid sha256:eaedce9b12e4e971bf1303e1db5f7cae685f65d91ea995f695c150487ab50054size 1383802880123version https://git-lfs.github.com/spec/v1oid sha256:d671f5e21b2affa3df53ef4889912077e5539f8638289ec70312e943e5fed699size 1287981056123version https://git-lfs.github.com/spec/v1oid sha256:32ada5859df3916c78710eb6a4b556f4a4672741f4ea29de607ce407a5c23bd7size 1551190016123version https://git-lfs.github.com/spec/v1oid sha256:16821546b078b7306638b6626b050cc9fe2187dde7091f01a69b04f1ae93a94fsize 1630263296123version https://git-lfs.github.com/spec/v1oid sha256:024d592aa44ddf75af1a552ac618b7adeffe734890503c79d2ab678f142e29f6size 1559840768123version https://git-lfs.github.com/spec/v1oid sha256:83dc048a2d307a52dccb838afaeb6f0161caa2242538062ab6ba732145f6cb9asize 1798916096123version https://git-lfs.github.com/spec/v1oid sha256:434980c227bfc6b9d298e5cac9fd1a6a9817d388f49e6188bb0078c14a1f3142size 1839650816123version https://git-lfs.github.com/spec/v1oid sha256:7e28b57eaa5859483f136ac51a8f9f6f0bffb0bf7e0e3a979f494634fa94e46esize 1798916096123version https://git-lfs.github.com/spec/v1oid sha256:4914e43b0c6c5aa28b2349f1e3684c6eecacd86f76bf797c886a5841b28a66fdsize 2062125056123version https://git-lfs.github.com/spec/v1oid sha256:f883b0057be9312b6929464ea6c0b0d56284ff3ee045ecda1e55389f33b5b948size 2669070336.gitattributes+12
README.mdAdded+90
gemma-2b-coder-Q2_K.ggufAdded+3
gemma-2b-coder-Q3_K_L.ggufAdded+3
gemma-2b-coder-Q3_K_M.ggufAdded+3
gemma-2b-coder-Q3_K_S.ggufAdded+3
gemma-2b-coder-Q4_0.ggufAdded+3
gemma-2b-coder-Q4_K_M.ggufAdded+3
gemma-2b-coder-Q4_K_S.ggufAdded+3
gemma-2b-coder-Q5_0.ggufAdded+3
gemma-2b-coder-Q5_K_M.ggufAdded+3
gemma-2b-coder-Q5_K_S.ggufAdded+3
gemma-2b-coder-Q6_K.ggufAdded+3
gemma-2b-coder-Q8_0.ggufAdded+3