Instructions to use fangloveskari/ORCA_LLaMA_70B_QLoRA with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use fangloveskari/ORCA_LLaMA_70B_QLoRA with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="fangloveskari/ORCA_LLaMA_70B_QLoRA")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("fangloveskari/ORCA_LLaMA_70B_QLoRA") model = AutoModelForCausalLM.from_pretrained("fangloveskari/ORCA_LLaMA_70B_QLoRA", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use fangloveskari/ORCA_LLaMA_70B_QLoRA with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "fangloveskari/ORCA_LLaMA_70B_QLoRA" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "fangloveskari/ORCA_LLaMA_70B_QLoRA", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/fangloveskari/ORCA_LLaMA_70B_QLoRA
- SGLang
How to use fangloveskari/ORCA_LLaMA_70B_QLoRA 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 "fangloveskari/ORCA_LLaMA_70B_QLoRA" \ --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": "fangloveskari/ORCA_LLaMA_70B_QLoRA", "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 "fangloveskari/ORCA_LLaMA_70B_QLoRA" \ --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": "fangloveskari/ORCA_LLaMA_70B_QLoRA", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use fangloveskari/ORCA_LLaMA_70B_QLoRA with Docker Model Runner:
docker model run hf.co/fangloveskari/ORCA_LLaMA_70B_QLoRA
About QLoRA Implementation
Hi, thanks for sharing the great work! I was wondering what is the QLoRA implementation you use for the fine-tuning. Do you use the official QLoRA code (https://github.com/artidoro/qlora/tree/main) or you implement it by yourself? Besides, could you describe the hardware settings and the corresponding training speed?
nop, I use https://github.com/hiyouga/LLaMA-Efficient-Tuning.
I use deepspeed ZERO-2 + FlashAttention2 + 4bit QLoRA to training with 8 A100(80G), then the batch size can be set to around 16.
as for training speed, It may take 5-6 hours for training? I'm not really clear with that.
btw, Our team tends to upload a better model and details about the dataset mix-up strategy, the hardware setting, the training settings and steps will also be provided, but it may take several days for that.
Thanks for your prompt reply. I am anticipating your following work!