Instructions to use gsaivinay/Platypus-30B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use gsaivinay/Platypus-30B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="gsaivinay/Platypus-30B")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("gsaivinay/Platypus-30B") model = AutoModelForCausalLM.from_pretrained("gsaivinay/Platypus-30B") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use gsaivinay/Platypus-30B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "gsaivinay/Platypus-30B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "gsaivinay/Platypus-30B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/gsaivinay/Platypus-30B
- SGLang
How to use gsaivinay/Platypus-30B 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 "gsaivinay/Platypus-30B" \ --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": "gsaivinay/Platypus-30B", "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 "gsaivinay/Platypus-30B" \ --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": "gsaivinay/Platypus-30B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use gsaivinay/Platypus-30B with Docker Model Runner:
docker model run hf.co/gsaivinay/Platypus-30B
🥳 Platypus-30B has arrived!
Platypus-30B is an instruction fine-tuned model based on the LLaMA-30B transformer architecture.
| Metric | Value |
|---|---|
| MMLU (5-shot) | 64.1 |
| ARC (25-shot) | 57.6 |
| HellaSwag (10-shot) | 81.9 |
| TruthfulQA (0-shot) | 45.3 |
| Avg. | 62.2 |
We use state-of-the-art Language Model Evaluation Harness to run the benchmark tests above.
Model Details
- Trained by: Cole Hunter & Ariel Lee
- Model type: Platypus-30B is an auto-regressive language model based on the LLaMA transformer architecture.
- Language(s): English
- License for base weights: License for the base LLaMA model's weights is Meta's non-commercial bespoke license.
| Hyperparameter | Value |
|---|---|
| 33B | |
| 6656 | |
| 60 | |
| 52 |
Training Dataset
Dataset of highly filtered and curated question and answer pairs. Release TBD.
Training Procedure
lilloukas/Platypus-30B was instruction fine-tuned using LoRA on 4 A100 80GB. For training details and inference instructions please see the Platypus-30B GitHub repo.
Reproducing Evaluation Results
Install LM Evaluation Harness:
git clone https://github.com/EleutherAI/lm-evaluation-harness
cd lm-evaluation-harness
pip install -e .
Each task was evaluated on a single A100 80GB GPU.
ARC:
python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks arc_challenge --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/arc_challenge_25shot.json --device cuda --num_fewshot 25
HellaSwag:
python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks hellaswag --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/hellaswag_10shot.json --device cuda --num_fewshot 10
MMLU:
python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks hendrycksTest-* --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/mmlu_5shot.json --device cuda --num_fewshot 5
TruthfulQA:
python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks truthfulqa_mc --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/truthfulqa_0shot.json --device cuda
Limitations and bias
The base LLaMA model is trained on various data, some of which may contain offensive, harmful, and biased content that can lead to toxic behavior. See Section 5.1 of the LLaMA paper. We have not performed any studies to determine how fine-tuning on the aforementioned datasets affect the model's behavior and toxicity. Do not treat chat responses from this model as a substitute for human judgment or as a source of truth. Please use responsibly.
Citations
@article{touvron2023llama,
title={LLaMA: Open and Efficient Foundation Language Models},
author={Touvron, Hugo and Lavril, Thibaut and Izacard, Gautier and Martinet, Xavier and Lachaux, Marie-Anne and Lacroix, Timoth{\'e}e and Rozi{\`e}re, Baptiste and Goyal, Naman and Hambro, Eric and Azhar, Faisal and Rodriguez, Aurelien and Joulin, Armand and Grave, Edouard and Lample, Guillaume},
journal={arXiv preprint arXiv:2302.13971},
year={2023}
}
@article{hu2021lora,
title={LoRA: Low-Rank Adaptation of Large Language Models},
author={Hu, Edward J. and Shen, Yelong and Wallis, Phillip and Allen-Zhu, Zeyuan and Li, Yuanzhi and Wang, Shean and Chen, Weizhu},
journal={CoRR},
year={2021}
}
- Downloads last month
- 6