Instructions to use Alignment-Lab-AI/ALAI-gemma-7b 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 Alignment-Lab-AI/ALAI-gemma-7b 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 Alignment-Lab-AI/ALAI-gemma-7b # Run inference directly in the terminal: llama cli -hf Alignment-Lab-AI/ALAI-gemma-7b
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Alignment-Lab-AI/ALAI-gemma-7b # Run inference directly in the terminal: llama cli -hf Alignment-Lab-AI/ALAI-gemma-7b
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 Alignment-Lab-AI/ALAI-gemma-7b # Run inference directly in the terminal: ./llama-cli -hf Alignment-Lab-AI/ALAI-gemma-7b
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 Alignment-Lab-AI/ALAI-gemma-7b # Run inference directly in the terminal: ./build/bin/llama-cli -hf Alignment-Lab-AI/ALAI-gemma-7b
Use Docker
docker model run hf.co/Alignment-Lab-AI/ALAI-gemma-7b
- LM Studio
- Jan
- Ollama
How to use Alignment-Lab-AI/ALAI-gemma-7b with Ollama:
ollama run hf.co/Alignment-Lab-AI/ALAI-gemma-7b
- Unsloth Studio
How to use Alignment-Lab-AI/ALAI-gemma-7b 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 Alignment-Lab-AI/ALAI-gemma-7b 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 Alignment-Lab-AI/ALAI-gemma-7b to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Alignment-Lab-AI/ALAI-gemma-7b to start chatting
- Docker Model Runner
How to use Alignment-Lab-AI/ALAI-gemma-7b with Docker Model Runner:
docker model run hf.co/Alignment-Lab-AI/ALAI-gemma-7b
- Lemonade
How to use Alignment-Lab-AI/ALAI-gemma-7b with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Alignment-Lab-AI/ALAI-gemma-7b
Run and chat with the model
lemonade run user.ALAI-gemma-7b-{{QUANT_TAG}}List all available models
lemonade list
- Atomic Chat
| { | |
| "add_bos_token": true, | |
| "add_eos_token": false, | |
| "added_tokens_decoder": { | |
| "0": { | |
| "content": "<pad>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false, | |
| "special": true | |
| }, | |
| "1": { | |
| "content": "<eos>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false, | |
| "special": true | |
| }, | |
| "2": { | |
| "content": "<bos>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false, | |
| "special": true | |
| }, | |
| "3": { | |
| "content": "<unk>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false, | |
| "special": true | |
| } | |
| }, | |
| "bos_token": "<bos>", | |
| "chat_template": "{% if messages[0]['role'] == 'system' %}{{ raise_exception('System role not supported') }}{% endif %}{% for message in messages %}{% if (message['role'] == 'user') != (loop.index0 % 2 == 0) %}{{ raise_exception('Conversation roles must alternate user/assistant/user/assistant/...') }}{% endif %}{% if (message['role'] == 'assistant') %}{% set role = 'model' %}{% else %}{% set role = message['role'] %}{% endif %}{{ '<start_of_turn>' + role + '\n' + message['content'] | trim + '<end_of_turn>\n' }}{% endfor %}{% if add_generation_prompt %}{{'<start_of_turn>model\n'}}{% endif %}", | |
| "clean_up_tokenization_spaces": false, | |
| "eos_token": "<eos>", | |
| "legacy": null, | |
| "model_max_length": 1000000000000000019884624838656, | |
| "pad_token": "<pad>", | |
| "sp_model_kwargs": {}, | |
| "spaces_between_special_tokens": false, | |
| "tokenizer_class": "GemmaTokenizer", | |
| "unk_token": "<unk>", | |
| "use_default_system_prompt": false | |
| } | |