Upload folder using huggingface_hub
Browse files
README.md
ADDED
@@ -0,0 +1,87 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags:
|
3 |
+
- DeepCode-7B-Aurora-v4
|
4 |
+
- DeepCode-7B-Aurora-v5
|
5 |
+
- DeepCode-7B-Aurora-v6
|
6 |
+
- DeepCode-7B-Aurora-v7
|
7 |
+
- DeepCode-7B-Aurora-v8
|
8 |
+
- DeepCode-7B-Aurora-v9
|
9 |
+
- DeepCode-7B-Aurora-v10
|
10 |
+
base_model:
|
11 |
+
- DeepCode-7B-Aurora-v4
|
12 |
+
- DeepCode-7B-Aurora-v5
|
13 |
+
- DeepCode-7B-Aurora-v6
|
14 |
+
- DeepCode-7B-Aurora-v7
|
15 |
+
- DeepCode-7B-Aurora-v8
|
16 |
+
- DeepCode-7B-Aurora-v9
|
17 |
+
- DeepCode-7B-Aurora-v10
|
18 |
+
---
|
19 |
+
|
20 |
+
# DeepCode-7B-Aurora-v11
|
21 |
+
|
22 |
+
DeepCode-7B-Aurora-v11 is a merge of the following models using [LazyMergekit](https://colab.research.google.com/drive/1obulZ1ROXHjYLn6PPZJwRR6GzgQogxxb?usp=sharing):
|
23 |
+
* [DeepCode-7B-Aurora-v4](https://huggingface.co/DeepCode-7B-Aurora-v4)
|
24 |
+
* [DeepCode-7B-Aurora-v5](https://huggingface.co/DeepCode-7B-Aurora-v5)
|
25 |
+
* [DeepCode-7B-Aurora-v6](https://huggingface.co/DeepCode-7B-Aurora-v6)
|
26 |
+
* [DeepCode-7B-Aurora-v7](https://huggingface.co/DeepCode-7B-Aurora-v7)
|
27 |
+
* [DeepCode-7B-Aurora-v8](https://huggingface.co/DeepCode-7B-Aurora-v8)
|
28 |
+
* [DeepCode-7B-Aurora-v9](https://huggingface.co/DeepCode-7B-Aurora-v9)
|
29 |
+
* [DeepCode-7B-Aurora-v10](https://huggingface.co/DeepCode-7B-Aurora-v10)
|
30 |
+
|
31 |
+
## 🧩 Configuration
|
32 |
+
|
33 |
+
```yaml
|
34 |
+
models:
|
35 |
+
- model: DeepCode-7B-Aurora-v4
|
36 |
+
parameters:
|
37 |
+
weight: 1
|
38 |
+
- model: DeepCode-7B-Aurora-v5
|
39 |
+
parameters:
|
40 |
+
weight: 1
|
41 |
+
- model: DeepCode-7B-Aurora-v6
|
42 |
+
parameters:
|
43 |
+
weight: 1
|
44 |
+
- model: DeepCode-7B-Aurora-v7
|
45 |
+
parameters:
|
46 |
+
weight: 1
|
47 |
+
- model: DeepCode-7B-Aurora-v8
|
48 |
+
parameters:
|
49 |
+
weight: 1
|
50 |
+
- model: DeepCode-7B-Aurora-v9
|
51 |
+
parameters:
|
52 |
+
weight: 1
|
53 |
+
- model: DeepCode-7B-Aurora-v10
|
54 |
+
parameters:
|
55 |
+
weight: 1
|
56 |
+
merge_method: task_arithmetic
|
57 |
+
base_model: DeepCode-7B-Aurora-v7
|
58 |
+
parameters:
|
59 |
+
normalize: true
|
60 |
+
int8_mask: true
|
61 |
+
dtype: float16
|
62 |
+
```
|
63 |
+
|
64 |
+
## 💻 Usage
|
65 |
+
|
66 |
+
```python
|
67 |
+
os.system(f"pip install -qU transformers accelerate")
|
68 |
+
|
69 |
+
from transformers import AutoTokenizer
|
70 |
+
import transformers
|
71 |
+
import torch
|
72 |
+
|
73 |
+
model = "ALBADDAWI/DeepCode-7B-Aurora-v11"
|
74 |
+
messages = [{"role": "user", "content": "What is a large language model?"}]
|
75 |
+
|
76 |
+
tokenizer = AutoTokenizer.from_pretrained(model)
|
77 |
+
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
|
78 |
+
pipeline = transformers.pipeline(
|
79 |
+
"text-generation",
|
80 |
+
model=model,
|
81 |
+
torch_dtype=torch.float16,
|
82 |
+
device_map="auto",
|
83 |
+
)
|
84 |
+
|
85 |
+
outputs = pipeline(prompt, max_new_tokens=256, do_sample=True, temperature=0.7, top_k=50, top_p=0.95)
|
86 |
+
print(outputs[0]["generated_text"])
|
87 |
+
```
|