Update README.md
Browse files
README.md
CHANGED
@@ -1,3 +1,79 @@
|
|
1 |
---
|
|
|
|
|
|
|
|
|
|
|
2 |
license: cc-by-nc-4.0
|
3 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
+
language:
|
3 |
+
- ko
|
4 |
+
|
5 |
+
library_name: transformers
|
6 |
+
pipeline_tag: text-generation
|
7 |
license: cc-by-nc-4.0
|
8 |
---
|
9 |
+
|
10 |
+
# **Synatra-7B-Instruct-v0.3π§**
|
11 |
+
![Synatra-7B-Instruct-v0.3](./Synatra.png)
|
12 |
+
|
13 |
+
# Support Me
|
14 |
+
μλνΈλΌλ κ°μΈ νλ‘μ νΈλ‘, 1μΈμ μμμΌλ‘ κ°λ°λκ³ μμ΅λλ€. λͺ¨λΈμ΄ λ§μμ λμ
¨λ€λ©΄ μ½κ°μ μ°κ΅¬λΉ μ§μμ μ΄λ¨κΉμ?
|
15 |
+
[<img src="https://cdn.buymeacoffee.com/buttons/default-orange.png" alt="Buy me a Coffee" width="217" height="50">](https://www.buymeacoffee.com/mwell)
|
16 |
+
|
17 |
+
Wanna be a sponser? Contact me on Telegram **AlzarTakkarsen**
|
18 |
+
|
19 |
+
## License
|
20 |
+
|
21 |
+
This model is strictly [*non-commercial*](https://creativecommons.org/licenses/by-nc/4.0/) (**cc-by-nc-4.0**) use only.
|
22 |
+
The "Model" is completely free (ie. base model, derivates, merges/mixes) to use for non-commercial purposes as long as the the included **cc-by-nc-4.0** license in any parent repository, and the non-commercial use statute remains, regardless of other models' licences.
|
23 |
+
The licence can be changed after new model released. If you are to use this model for commercial purpose, Contact me.
|
24 |
+
|
25 |
+
## Model Details
|
26 |
+
**Base Model**
|
27 |
+
[mistralai/Mistral-7B-Instruct-v0.1](https://huggingface.co/mistralai/Mistral-7B-Instruct-v0.1)
|
28 |
+
|
29 |
+
**Trained On**
|
30 |
+
A6000 48GB * 8
|
31 |
+
|
32 |
+
## TODO
|
33 |
+
|
34 |
+
- ~~``RP κΈ°λ° νλ λͺ¨λΈ μ μ``~~ β
|
35 |
+
- ~~``λ°μ΄ν°μ
μ μ ``~~ β
|
36 |
+
- μΈμ΄ μ΄ν΄λ₯λ ₯ κ°μ
|
37 |
+
- ~~``μμ 보μ``~~ β
|
38 |
+
- ν ν¬λμ΄μ λ³κ²½
|
39 |
+
|
40 |
+
## Instruction format
|
41 |
+
|
42 |
+
It follows [ChatML](https://github.com/openai/openai-python/blob/main/chatml.md) format.
|
43 |
+
|
44 |
+
# **Model Benchmark**
|
45 |
+
|
46 |
+
## Ko-LLM-Leaderboard
|
47 |
+
|
48 |
+
On Benchmarking...
|
49 |
+
|
50 |
+
# **Implementation Code**
|
51 |
+
|
52 |
+
Since, chat_template already contains insturction format above.
|
53 |
+
You can use the code below.
|
54 |
+
|
55 |
+
```python
|
56 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
57 |
+
|
58 |
+
device = "cuda" # the device to load the model onto
|
59 |
+
|
60 |
+
model = AutoModelForCausalLM.from_pretrained("maywell/Synatra-7B-Instruct-v0.3")
|
61 |
+
tokenizer = AutoTokenizer.from_pretrained("maywell/Synatra-7B-Instruct-v0.3")
|
62 |
+
|
63 |
+
messages = [
|
64 |
+
{"role": "user", "content": "λ°λλλ μλ νμμμ΄μΌ?"},
|
65 |
+
]
|
66 |
+
|
67 |
+
encodeds = tokenizer.apply_chat_template(messages, return_tensors="pt")
|
68 |
+
|
69 |
+
model_inputs = encodeds.to(device)
|
70 |
+
model.to(device)
|
71 |
+
|
72 |
+
generated_ids = model.generate(model_inputs, max_new_tokens=1000, do_sample=True)
|
73 |
+
decoded = tokenizer.batch_decode(generated_ids)
|
74 |
+
print(decoded[0])
|
75 |
+
```
|
76 |
+
|
77 |
+
# Why It's benchmark score is lower than preview version?
|
78 |
+
|
79 |
+
**Apparently**, Preview model uses Alpaca Style prompt which has no pre-fix. But ChatML do.
|