Instructions to use google/gemma-4-31B-it-assistant with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use google/gemma-4-31B-it-assistant with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("google/gemma-4-31B-it-assistant") model = AutoModelForCausalLM.from_pretrained("google/gemma-4-31B-it-assistant", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download generation_config.json from google/gemma-4-31B-it-assistant: direct link, hf CLI and curl.
- Browser
- Download file 307 Bytes
-
https://huggingface.co/google/gemma-4-31B-it-assistant/resolve/main/generation_config.json
- Command line
-
hf download hf://google/gemma-4-31B-it-assistant/generation_config.json
-
curl -L -o generation_config.json https://huggingface.co/google/gemma-4-31B-it-assistant/resolve/main/generation_config.json
307 Bytes
| { | |
| "bos_token_id": 2, | |
| "do_sample": true, | |
| "eos_token_id": [ | |
| 1, | |
| 106, | |
| 50 | |
| ], | |
| "is_assistant": true, | |
| "num_assistant_tokens": 6, | |
| "num_assistant_tokens_schedule": "constant", | |
| "pad_token_id": 0, | |
| "temperature": 1.0, | |
| "top_k": 64, | |
| "top_p": 0.95, | |
| "transformers_version": "5.7.0.dev0" | |
| } |