Instructions to use Monero/oasst-alpaca13b-4epoch-4bit-128g with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Monero/oasst-alpaca13b-4epoch-4bit-128g with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Monero/oasst-alpaca13b-4epoch-4bit-128g")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Monero/oasst-alpaca13b-4epoch-4bit-128g") model = AutoModelForCausalLM.from_pretrained("Monero/oasst-alpaca13b-4epoch-4bit-128g", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Monero/oasst-alpaca13b-4epoch-4bit-128g with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Monero/oasst-alpaca13b-4epoch-4bit-128g" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Monero/oasst-alpaca13b-4epoch-4bit-128g", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Monero/oasst-alpaca13b-4epoch-4bit-128g
- SGLang
How to use Monero/oasst-alpaca13b-4epoch-4bit-128g 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 "Monero/oasst-alpaca13b-4epoch-4bit-128g" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Monero/oasst-alpaca13b-4epoch-4bit-128g", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "Monero/oasst-alpaca13b-4epoch-4bit-128g" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Monero/oasst-alpaca13b-4epoch-4bit-128g", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Monero/oasst-alpaca13b-4epoch-4bit-128g with Docker Model Runner:
docker model run hf.co/Monero/oasst-alpaca13b-4epoch-4bit-128g
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
datasets:
|
| 3 |
+
- OpenAssistant/oasst1
|
| 4 |
+
---
|
| 5 |
+
|
| 6 |
+
<p><strong><font size="5">Information</font></strong></p>
|
| 7 |
+
OpenAssistant-Alpaca-13B-4-bit working with GPTQ versions used in Oobabooga's Text Generation Webui and KoboldAI.
|
| 8 |
+
<br>This was made using https://huggingface.co/chavinlo/alpaca-13b and <a href="https://huggingface.co/serpdotai/llama-oasst-lora-13B">Serpdotai's Open Assistant 13b LoRa trained for 4 epochs</a> using Open Assistant's dataset.</p>
|
| 9 |
+
|
| 10 |
+
python llama.py /Models/alpaca13b-oaast4ep-lora c4 --wbits 4 --true-sequential --groupsize 128 --save_safetensors oasst-alpaca13b-4ep-lora-4bit-128g.safetensors
|
| 11 |
+
|
| 12 |
+
<p><strong><font size="5">Benchmarks</font></strong></p>
|
| 13 |
+
|
| 14 |
+
<p><strong><font size="4">--true-sequential --groupsize 128</font></strong></p>
|
| 15 |
+
|
| 16 |
+
<strong>Wikitext2</strong>: 6.854333400726318
|
| 17 |
+
|
| 18 |
+
<strong>Ptb-New</strong>: 12.411578178405762
|
| 19 |
+
|
| 20 |
+
<strong>C4-New</strong>: 9.355494499206543
|
| 21 |
+
|
| 22 |
+
<strong>Note</strong>: This version uses <i>--groupsize 128</i>, resulting in better evaluations.
|