Create README.md
Browse files
README.md
ADDED
@@ -0,0 +1,128 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
datasets:
|
3 |
+
- databricks/databricks-dolly-15k
|
4 |
+
- OpenAssistant/oasst1
|
5 |
+
- sahil2801/CodeAlpaca-20k
|
6 |
+
language:
|
7 |
+
- en
|
8 |
+
---
|
9 |
+
|
10 |
+
# Tulu 30B
|
11 |
+
|
12 |
+
This model is a 30B LLaMa model finetuned on a mixture of instruction datasets (FLAN V2, CoT, Dolly, Open Assistant 1, GPT4-Alpaca, Code-Alpaca, and ShareGPT).
|
13 |
+
*Please note this is a model diff - see below for usage instructions*.
|
14 |
+
|
15 |
+
This was trained as part of the paper [How Far Can Camels Go? Exploring the State of Instruction Tuning on Open Resources](https://arxiv.org/abs/2306.04751).
|
16 |
+
The codebase used to train and evaluate this model can be found at [https://github.com/allenai/open-instruct](https://github.com/allenai/open-instruct).
|
17 |
+
|
18 |
+
This model is licensed under the AI model license given in LICENSE.txt along with the original Llama license (llama_license.txt).
|
19 |
+
|
20 |
+
## Usage
|
21 |
+
|
22 |
+
We assume you have access to a LLaMa model in HF format already. You can find details on getting access and converting the model here:
|
23 |
+
[https://huggingface.co/docs/transformers/main/model_doc/llama](https://huggingface.co/docs/transformers/main/model_doc/llama)
|
24 |
+
|
25 |
+
Clone [https://github.com/allenai/open-instruct](https://github.com/allenai/open-instruct) and install the required dependencies, or just copy `scripts/weight_diff.py`
|
26 |
+
and install the minimal requirements listed in `weight-diff-requirements.txt`. Then download or clone this model diff to the same machine.
|
27 |
+
|
28 |
+
Then, run:
|
29 |
+
```bash
|
30 |
+
python scripts/weight_diff.py recover --path_raw ${hf_llama_path} --path_tuned ${output_path} --path_diff ${diff_location}
|
31 |
+
```
|
32 |
+
|
33 |
+
And you will have a recovered model! Note this takes up a decent amount of RAM, especially for the larger models.
|
34 |
+
|
35 |
+
## Input Format
|
36 |
+
|
37 |
+
The model is trained to use the following format (note the newlines):
|
38 |
+
```
|
39 |
+
<|user|>
|
40 |
+
Your message here!
|
41 |
+
<|assistant|>
|
42 |
+
```
|
43 |
+
|
44 |
+
For best results, format all inputs in this manner.
|
45 |
+
|
46 |
+
## Performance
|
47 |
+
|
48 |
+
Here is the performance of this model across benchmarks explored in our paper [How Far Can Camels Go? Exploring the State of Instruction Tuning on Open Resources](https://arxiv.org/abs/2306.04751):
|
49 |
+
|
50 |
+
| MMLU 0-shot | MMLU 5-shot | GSM Direct | GSM CoT | BBH Direct | BBH CoT | TydiQA Gold-Passage | TydiQA Closed-book | Codex-Eval Pass@1 | Codex-Eval Pass@10 | AlpacaFarm vs Davinci-003 | Average |
|
51 |
+
|:-----------:|:-----------:|:----------:|:-------:|:----------:|:-------:|:-------------------:|:------------------:|:-----------------:|:------------------:|:-------------------------:|---------|
|
52 |
+
| 57.7 | 58.4 | 6.0 | 51.0 | 45.8 | 48.7 | 58.2 | 12.3 | 25.4 | 46.0 | 63.5 | 44.7 |
|
53 |
+
|
54 |
+
If you use this model, please cite our work, the llama paper, and the original datasets:
|
55 |
+
|
56 |
+
```
|
57 |
+
@misc{wang2023far,
|
58 |
+
title={How Far Can Camels Go? Exploring the State of Instruction Tuning on Open Resources},
|
59 |
+
author={Yizhong Wang and Hamish Ivison and Pradeep Dasigi and Jack Hessel and Tushar Khot and Khyathi Raghavi Chandu and David Wadden and Kelsey MacMillan and Noah A. Smith and Iz Beltagy and Hannaneh Hajishirzi},
|
60 |
+
year={2023},
|
61 |
+
eprint={2306.04751},
|
62 |
+
archivePrefix={arXiv},
|
63 |
+
primaryClass={cs.CL}
|
64 |
+
}
|
65 |
+
```
|
66 |
+
|
67 |
+
```
|
68 |
+
@misc{touvron2023llama,
|
69 |
+
title={LLaMA: Open and Efficient Foundation Language Models},
|
70 |
+
author={Hugo Touvron and Thibaut Lavril and Gautier Izacard and Xavier Martinet and Marie-Anne Lachaux and Timothée Lacroix and Baptiste Rozière and Naman Goyal and Eric Hambro and Faisal Azhar and Aurelien Rodriguez and Armand Joulin and Edouard Grave and Guillaume Lample},
|
71 |
+
year={2023},
|
72 |
+
eprint={2302.13971},
|
73 |
+
archivePrefix={arXiv},
|
74 |
+
primaryClass={cs.CL}
|
75 |
+
}
|
76 |
+
```
|
77 |
+
|
78 |
+
```
|
79 |
+
@misc{dolly,
|
80 |
+
author = {Databricks},
|
81 |
+
title = {Free Dolly: Introducing the World's First Truly Open Instruction-Tuned LLM},
|
82 |
+
year = {2023},
|
83 |
+
publisher = {GitHub},
|
84 |
+
journal = {GitHub repository},
|
85 |
+
howpublished = {Blog post},
|
86 |
+
url = {https://www.databricks.com/blog/2023/04/12/dolly-first-open-commercially-viable-instruction-tuned-llm}
|
87 |
+
}
|
88 |
+
```
|
89 |
+
|
90 |
+
```
|
91 |
+
@article{longpre2023flan,
|
92 |
+
title={The Flan Collection: Designing Data and Methods for Effective Instruction Tuning},
|
93 |
+
author={Longpre, Shayne and Hou, Le and Vu, Tu and Webson, Albert and Chung, Hyung Won and Tay, Yi and Zhou, Denny and Le, Quoc V and Zoph, Barret and Wei, Jason and others},
|
94 |
+
journal={arXiv preprint arXiv:2301.13688},
|
95 |
+
year={2023}
|
96 |
+
}
|
97 |
+
```
|
98 |
+
|
99 |
+
```
|
100 |
+
@misc{köpf2023openassistant,
|
101 |
+
title={OpenAssistant Conversations -- Democratizing Large Language Model Alignment},
|
102 |
+
author={Andreas Köpf and Yannic Kilcher and Dimitri von Rütte and Sotiris Anagnostidis and Zhi-Rui Tam and Keith Stevens and Abdullah Barhoum and Nguyen Minh Duc and Oliver Stanley and Richárd Nagyfi and Shahul ES and Sameer Suri and David Glushkov and Arnav Dantuluri and Andrew Maguire and Christoph Schuhmann and Huu Nguyen and Alexander Mattick},
|
103 |
+
year={2023},
|
104 |
+
eprint={2304.07327},
|
105 |
+
archivePrefix={arXiv},
|
106 |
+
primaryClass={cs.CL}
|
107 |
+
}
|
108 |
+
```
|
109 |
+
|
110 |
+
```
|
111 |
+
@article{peng2023instruction,
|
112 |
+
title={Instruction Tuning with GPT-4},
|
113 |
+
author={Peng, Baolin and Li, Chunyuan and He, Pengcheng and Galley, Michel and Gao, Jianfeng},
|
114 |
+
journal={arXiv preprint arXiv:2304.03277},
|
115 |
+
year={2023}
|
116 |
+
}
|
117 |
+
```
|
118 |
+
|
119 |
+
```
|
120 |
+
@misc{codealpaca,
|
121 |
+
author = {Sahil Chaudhary},
|
122 |
+
title = {Code Alpaca: An Instruction-following LLaMA model for code generation},
|
123 |
+
year = {2023},
|
124 |
+
publisher = {GitHub},
|
125 |
+
journal = {GitHub repository},
|
126 |
+
howpublished = {\url{https://github.com/sahil280114/codealpaca}},
|
127 |
+
}
|
128 |
+
```
|