Text Generation
Transformers
Safetensors
aion_instruct
custom_code
summarization
rewriting
chat
conversational
Instructions to use microsoft/Aion-1.0-Instruct-2.3B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use microsoft/Aion-1.0-Instruct-2.3B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="microsoft/Aion-1.0-Instruct-2.3B", 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("microsoft/Aion-1.0-Instruct-2.3B", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use microsoft/Aion-1.0-Instruct-2.3B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "microsoft/Aion-1.0-Instruct-2.3B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "microsoft/Aion-1.0-Instruct-2.3B", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/microsoft/Aion-1.0-Instruct-2.3B
- SGLang
How to use microsoft/Aion-1.0-Instruct-2.3B 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 "microsoft/Aion-1.0-Instruct-2.3B" \ --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": "microsoft/Aion-1.0-Instruct-2.3B", "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 "microsoft/Aion-1.0-Instruct-2.3B" \ --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": "microsoft/Aion-1.0-Instruct-2.3B", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use microsoft/Aion-1.0-Instruct-2.3B with Docker Model Runner:
docker model run hf.co/microsoft/Aion-1.0-Instruct-2.3B
Update README.md
Browse files
README.md
CHANGED
|
@@ -9,7 +9,7 @@ language:
|
|
| 9 |
- zh
|
| 10 |
- ja
|
| 11 |
license: mit
|
| 12 |
-
license_link: https://huggingface.co/
|
| 13 |
library_name: transformers
|
| 14 |
pipeline_tag: text-generation
|
| 15 |
tags:
|
|
@@ -23,8 +23,6 @@ tags:
|
|
| 23 |
|
| 24 |
# Aion 1.0 Instruct
|
| 25 |
|
| 26 |
-
<img src="images/ASG%20Logo.svg" alt="ASG Logo" class="block dark:hidden" width="25%">
|
| 27 |
-
<img src="images/ASG_Logo_white.svg" alt="ASG Logo" class="hidden dark:block" width="25%">
|
| 28 |
Microsoft Windows Applied Sciences Group
|
| 29 |
|
| 30 |
## Model Description
|
|
@@ -140,7 +138,7 @@ The model uses custom modeling code, so `trust_remote_code=True` is required. It
|
|
| 140 |
```python
|
| 141 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 142 |
|
| 143 |
-
model_id = "
|
| 144 |
|
| 145 |
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
|
| 146 |
model = AutoModelForCausalLM.from_pretrained(
|
|
|
|
| 9 |
- zh
|
| 10 |
- ja
|
| 11 |
license: mit
|
| 12 |
+
license_link: https://huggingface.co/microsoft/Aion-1.0-Instruct-2.3B/blob/main/LICENSE
|
| 13 |
library_name: transformers
|
| 14 |
pipeline_tag: text-generation
|
| 15 |
tags:
|
|
|
|
| 23 |
|
| 24 |
# Aion 1.0 Instruct
|
| 25 |
|
|
|
|
|
|
|
| 26 |
Microsoft Windows Applied Sciences Group
|
| 27 |
|
| 28 |
## Model Description
|
|
|
|
| 138 |
```python
|
| 139 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 140 |
|
| 141 |
+
model_id = "microsoft/Aion-1.0-Instruct-2.3B"
|
| 142 |
|
| 143 |
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
|
| 144 |
model = AutoModelForCausalLM.from_pretrained(
|