Instructions to use iamplus/Llama-2-70b-hf-ChatOrca-v1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use iamplus/Llama-2-70b-hf-ChatOrca-v1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="iamplus/Llama-2-70b-hf-ChatOrca-v1")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("iamplus/Llama-2-70b-hf-ChatOrca-v1") model = AutoModelForCausalLM.from_pretrained("iamplus/Llama-2-70b-hf-ChatOrca-v1") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use iamplus/Llama-2-70b-hf-ChatOrca-v1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "iamplus/Llama-2-70b-hf-ChatOrca-v1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "iamplus/Llama-2-70b-hf-ChatOrca-v1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/iamplus/Llama-2-70b-hf-ChatOrca-v1
- SGLang
How to use iamplus/Llama-2-70b-hf-ChatOrca-v1 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 "iamplus/Llama-2-70b-hf-ChatOrca-v1" \ --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": "iamplus/Llama-2-70b-hf-ChatOrca-v1", "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 "iamplus/Llama-2-70b-hf-ChatOrca-v1" \ --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": "iamplus/Llama-2-70b-hf-ChatOrca-v1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use iamplus/Llama-2-70b-hf-ChatOrca-v1 with Docker Model Runner:
docker model run hf.co/iamplus/Llama-2-70b-hf-ChatOrca-v1
Description :
This model is trained on a mix of Orca data and Open Source + Closed Multi-turn Conversation data to create a better reasoning model which is capable of holding multi-turn conversations as well.
The Dataset split description, Prompt description as well as Training Parameters are given below.
Prompt Description :
The prompt template for the first turn looks like this:
<s>[INST] <<SYS>>
{{ system_prompt }}
<</SYS>>
{{ user_message }} [/INST]
The prompt template for the multi-turn conversation looks like this:
<s>[INST] <<SYS>>
{{ system_prompt }}
<</SYS>>
{{ user_msg_1 }} [/INST] {{ model_answer_1 }} </s><s>[INST] {{ user_msg_2 }} [/INST]
This model follows the official Meta's chat model Prompt format. Please refer here : https://huggingface.co/blog/llama2#how-to-prompt-llama-2 on how to prompt the model for single/multi-turn conversations.
Base model : meta-llama/Llama-2-70b-hf
Data :
- 1M Orca dara (Gpt-4 Orca data - OpenOrca)
- 1.7M chat data (includes OpenAssistant Chat data, Ultrachat, and many more open source Chat Datasets)
- 30k OpenPlatypus data
Training Params :
Number of Epochs : 1
Batch Size : 64
Sequence Length : 4096
Learning Rate : 2e-5 (Cosine)
Weight Decay : 0.1
Gradient Clipping : 1.0
Gamma : 0.85
beta_1 : 0.9
beta_2 : 0.95
eps : 1e-5
Precision : bf16
Optimizer : Any Precision AdamW Optimizer
- Downloads last month
- 3