Downloads · 30 days
281
0% of all-time downloads
upstage/llama-65b-instruct
llama-65b-instruct is a text generation model from upstage. Use it when you need the model to write or continue text. It is set up for transformers.
Developed by: Upstage Backbone Model: LLaMA Variations: It has different model parameter sizes and sequence lengths: 30B/1024, 30B/2048, 65B/1024
Downloads · 30 days
281
0% of all-time downloads
All-time downloads
57.8K
Public
Repo size
261 GB
Likes
15
Public
Click a slice to open those files.
.bin131 GB · 100%
From the Hugging Face model README
### System:
{System}
### User:
{User}
### Assistant:
{Assistant}
rope_scaling optionimport torch
from transformers import AutoModelForCausalLM, AutoTokenizer, TextStreamer
tokenizer = AutoTokenizer.from_pretrained("upstage/llama-65b-instruct")
model = AutoModelForCausalLM.from_pretrained(
"upstage/llama-65b-instruct",
device_map="auto",
torch_dtype=torch.float16,
load_in_8bit=True,
rope_scaling={"type": "dynamic", "factor": 2} # allows handling of longer inputs
)
prompt = "### User:\nThomas is healthy, but he has to go to the hospital. What could be the reasons?\n\n### Assistant:\n"
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
del inputs["token_type_ids"]
streamer = TextStreamer(tokenizer, skip_prompt=True, skip_special_tokens=True)
output = model.generate(**inputs, streamer=streamer, use_cache=True, max_new_tokens=float('inf'))
output_text = tokenizer.decode(output[0], skip_special_tokens=True)
ARC-Challenge, HellaSwag, MMLU, and TruthfulQA.
We used the lm-evaluation-harness repository, specifically commit b281b0921b636bc36ad05c0b0b0763bd6dd43463| Model | H4(Avg) | ARC | HellaSwag | MMLU | TruthfulQA | MT_Bench | |
|---|---|---|---|---|---|---|---|
| Llama-2-70b-instruct-v2(Ours, Open LLM Leaderboard) | 73 | 71.1 | 87.9 | 70.6 | 62.2 | 7.44063 | |
| Llama-2-70b-instruct (Ours, Open LLM Leaderboard) | 72.3 | 70.9 | 87.5 | 69.8 | 61 | 7.24375 | |
| llama-65b-instruct (Ours, Open LLM Leaderboard) | 69.4 | 67.6 | 86.5 | 64.9 | 58.8 | ||
| Llama-2-70b-hf | 67.3 | 67.3 | 87.3 | 69.8 | 44.9 | ||
| llama-30b-instruct-2048 (Ours, Open LLM Leaderboard) | 67.0 | 64.9 | 84.9 | 61.9 | 56.3 | ||
| llama-30b-instruct (Ours, Open LLM Leaderboard) | 65.2 | 62.5 | 86.2 | 59.4 | 52.8 | ||
| llama-65b | 64.2 | 63.5 | 86.1 | 63.9 | 43.4 | ||
| falcon-40b-instruct | 63.4 | 61.6 | 84.3 | 55.4 | 52.5 |
# clone the repository
git clone https://github.com/EleutherAI/lm-evaluation-harness.git
# check out the specific commit
git checkout b281b0921b636bc36ad05c0b0b0763bd6dd43463
# change to the repository directory
cd lm-evaluation-harness