Instructions to use adamo1139/Apertus-8B-Instruct-2509-ungated with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use adamo1139/Apertus-8B-Instruct-2509-ungated with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="adamo1139/Apertus-8B-Instruct-2509-ungated") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("adamo1139/Apertus-8B-Instruct-2509-ungated") model = AutoModelForCausalLM.from_pretrained("adamo1139/Apertus-8B-Instruct-2509-ungated") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use adamo1139/Apertus-8B-Instruct-2509-ungated with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "adamo1139/Apertus-8B-Instruct-2509-ungated" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "adamo1139/Apertus-8B-Instruct-2509-ungated", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/adamo1139/Apertus-8B-Instruct-2509-ungated
- SGLang
How to use adamo1139/Apertus-8B-Instruct-2509-ungated 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 "adamo1139/Apertus-8B-Instruct-2509-ungated" \ --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": "adamo1139/Apertus-8B-Instruct-2509-ungated", "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 "adamo1139/Apertus-8B-Instruct-2509-ungated" \ --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": "adamo1139/Apertus-8B-Instruct-2509-ungated", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use adamo1139/Apertus-8B-Instruct-2509-ungated with Docker Model Runner:
docker model run hf.co/adamo1139/Apertus-8B-Instruct-2509-ungated
Update README.md
Browse files
README.md
CHANGED
|
@@ -10,16 +10,19 @@ tags:
|
|
| 10 |
- swiss-ai
|
| 11 |
- apertus
|
| 12 |
|
| 13 |
-
|
| 14 |
-
extra_gated_fields:
|
| 15 |
-
Your Name: text
|
| 16 |
-
Country: country
|
| 17 |
-
Affiliation: text
|
| 18 |
-
geo: ip_location
|
| 19 |
-
By clicking Submit below I accept the terms of use: checkbox
|
| 20 |
-
extra_gated_button_content: Submit
|
| 21 |
---
|
| 22 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23 |
# Apertus
|
| 24 |
|
| 25 |

|
|
|
|
| 10 |
- swiss-ai
|
| 11 |
- apertus
|
| 12 |
|
| 13 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
---
|
| 15 |
|
| 16 |
+
# Same model as original, but without privacy-violating gating mechanism.
|
| 17 |
+
|
| 18 |
+
### Apertus LLM Acceptable Use Policy
|
| 19 |
+
(1.0 | September 1, 2025) -Agreement - The Swiss National AI Institute (SNAI) is a partnership between the two Swiss Federal Institutes of Technology, ETH Zurich and EPFL.
|
| 20 |
+
|
| 21 |
+
By using the Apertus LLM you agree to indemnify, defend, and hold harmless ETH Zurich and EPFL against any third-party claims arising from your use of Apertus LLM.
|
| 22 |
+
|
| 23 |
+
The training data and the Apertus LLM may contain or generate information that directly or indirectly refers to an identifiable individual (Personal Data). You process Personal Data as independent controller in accordance with applicable data protection law. SNAI will regularly provide a file with hash values for download which you can apply as an output filter to your use of our Apertus LLM. The file reflects data protection deletion requests which have been addressed to SNAI as the developer of the Apertus LLM. It allows you to remove Personal Data contained in the model output. We strongly advise downloading and applying this output filter from SNAI every six months following the release of the model.
|
| 24 |
+
|
| 25 |
+
|
| 26 |
# Apertus
|
| 27 |
|
| 28 |

|