Text Generation
Transformers
Safetensors
aion_instruct
nvfp4
nvfp4a16
4-bit precision
compressed-tensors
llm-compressor
gptq
quantized
custom_code
conversational
8-bit precision
Instructions to use PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16", trust_remote_code=True) messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16
- SGLang
How to use PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16 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 "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16" \ --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": "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16", "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 "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16" \ --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": "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16 with Docker Model Runner:
docker model run hf.co/PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16
Point repository references at PureTensorAI
Browse files
README.md
CHANGED
|
@@ -22,7 +22,7 @@ NVFP4 quantization of [microsoft/Aion-1.0-Instruct-2.3B](https://huggingface.co/
|
|
| 22 |
|
| 23 |
This is a test release. It is not affiliated with or endorsed by Microsoft.
|
| 24 |
|
| 25 |
-
**Headline:** on full MMLU and full GSM8K this checkpoint is statistically indistinguishable from the BF16 model. Its outputs are not identical: it picks the same next token as BF16 about 90% of the time. For the variant that also quantizes activations to 4 bits, and loses quality doing so, see [
|
| 26 |
|
| 27 |
## What was done
|
| 28 |
|
|
@@ -86,7 +86,7 @@ All built by us from the same BF16 weights and scored the same way.
|
|
| 86 |
| GPTQ, mixed | `q_proj`, `k_proj` | 54.31 | 60.65 | 0.045 | 0.027 |
|
| 87 |
| GPTQ, mixed | `q_proj`, `k_proj`, `o_proj` | 54.37 | 59.29 | 0.055 | 0.034 |
|
| 88 |
| GPTQ, mixed | `q_proj`, `k_proj`, `o_proj`, `down_proj` | 54.02 | 57.62 | 0.064 | 0.042 |
|
| 89 |
-
| GPTQ, W4A4 ([sibling repo](https://huggingface.co/
|
| 90 |
| Round-to-nearest, weights only | none | 52.65 | 50.34 | 0.098 | 0.281 |
|
| 91 |
| Expanded MSE scales, weights only | none | 52.32 | 53.37 | 0.098 | 0.263 |
|
| 92 |
|
|
@@ -100,7 +100,7 @@ Calibration caveat: of the 512 calibration samples, 180 are math word problems (
|
|
| 100 |
import torch
|
| 101 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 102 |
|
| 103 |
-
repo = "
|
| 104 |
tok = AutoTokenizer.from_pretrained(repo, trust_remote_code=True)
|
| 105 |
model = AutoModelForCausalLM.from_pretrained(
|
| 106 |
repo, trust_remote_code=True, dtype=torch.bfloat16
|
|
|
|
| 22 |
|
| 23 |
This is a test release. It is not affiliated with or endorsed by Microsoft.
|
| 24 |
|
| 25 |
+
**Headline:** on full MMLU and full GSM8K this checkpoint is statistically indistinguishable from the BF16 model. Its outputs are not identical: it picks the same next token as BF16 about 90% of the time. For the variant that also quantizes activations to 4 bits, and loses quality doing so, see [PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4](https://huggingface.co/PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4).
|
| 26 |
|
| 27 |
## What was done
|
| 28 |
|
|
|
|
| 86 |
| GPTQ, mixed | `q_proj`, `k_proj` | 54.31 | 60.65 | 0.045 | 0.027 |
|
| 87 |
| GPTQ, mixed | `q_proj`, `k_proj`, `o_proj` | 54.37 | 59.29 | 0.055 | 0.034 |
|
| 88 |
| GPTQ, mixed | `q_proj`, `k_proj`, `o_proj`, `down_proj` | 54.02 | 57.62 | 0.064 | 0.042 |
|
| 89 |
+
| GPTQ, W4A4 ([sibling repo](https://huggingface.co/PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4)) | all layers | 52.74 | 55.12 | 0.095 | 0.077 |
|
| 90 |
| Round-to-nearest, weights only | none | 52.65 | 50.34 | 0.098 | 0.281 |
|
| 91 |
| Expanded MSE scales, weights only | none | 52.32 | 53.37 | 0.098 | 0.263 |
|
| 92 |
|
|
|
|
| 100 |
import torch
|
| 101 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 102 |
|
| 103 |
+
repo = "PureTensorAI/Aion-1.0-Instruct-2.3B-NVFP4A16"
|
| 104 |
tok = AutoTokenizer.from_pretrained(repo, trust_remote_code=True)
|
| 105 |
model = AutoModelForCausalLM.from_pretrained(
|
| 106 |
repo, trust_remote_code=True, dtype=torch.bfloat16
|