Instructions to use bastienp/Gemma-2-2B-Instruct-structured-output with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use bastienp/Gemma-2-2B-Instruct-structured-output with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("unsloth/gemma-2-2b-it") model = PeftModel.from_pretrained(base_model, "bastienp/Gemma-2-2B-Instruct-structured-output") - Transformers
How to use bastienp/Gemma-2-2B-Instruct-structured-output with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("bastienp/Gemma-2-2B-Instruct-structured-output", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use bastienp/Gemma-2-2B-Instruct-structured-output 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 bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M # Run inference directly in the terminal: llama cli -hf bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M # Run inference directly in the terminal: llama cli -hf bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
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 bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
Use Docker
docker model run hf.co/bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
- Llama new
- LM Studio
- Jan
- Ollama
How to use bastienp/Gemma-2-2B-Instruct-structured-output with Ollama:
ollama run hf.co/bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
- Unsloth Desktop
- Docker Model Runner
How to use bastienp/Gemma-2-2B-Instruct-structured-output with Docker Model Runner:
docker model run hf.co/bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
- Lemonade
How to use bastienp/Gemma-2-2B-Instruct-structured-output with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull bastienp/Gemma-2-2B-Instruct-structured-output:Q4_K_M
Run and chat with the model
lemonade run user.Gemma-2-2B-Instruct-structured-output-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Download tokenizer.json from bastienp/Gemma-2-2B-Instruct-structured-output: direct link, hf CLI and curl.
- Browser
- Download file 17.5 MB
-
https://huggingface.co/bastienp/Gemma-2-2B-Instruct-structured-output/resolve/main/tokenizer.json
- Command line
-
hf download hf://bastienp/Gemma-2-2B-Instruct-structured-output/tokenizer.json
-
curl -L -o tokenizer.json https://huggingface.co/bastienp/Gemma-2-2B-Instruct-structured-output/resolve/main/tokenizer.json
17.5 MB
- Xet hash:
- 468f89786a084f976ebe64a0fb2ecf73029025701e08d5a125aa4239fff2908e
- Size of remote file:
- 17.5 MB
- SHA256:
- 3f289bc05132635a8bc7aca7aa21255efd5e18f3710f43e3cdb96bcd41be4922
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.