grandell1234
commited on
Commit
•
34eb9a9
1
Parent(s):
cdfc926
Update README.md
Browse files
README.md
CHANGED
@@ -4,44 +4,64 @@ base_model:
|
|
4 |
- cognitivecomputations/dolphin-2.8-mistral-7b-v02
|
5 |
library_name: transformers
|
6 |
tags:
|
7 |
-
-
|
8 |
-
-
|
9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
---
|
11 |
-
#
|
12 |
-
|
13 |
-
This is a
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
47 |
```
|
|
|
|
4 |
- cognitivecomputations/dolphin-2.8-mistral-7b-v02
|
5 |
library_name: transformers
|
6 |
tags:
|
7 |
+
- code
|
8 |
+
- instruct
|
9 |
+
- llm
|
10 |
+
- 7b
|
11 |
+
- dolphin
|
12 |
+
license: apache-2.0
|
13 |
+
datasets:
|
14 |
+
- cognitivecomputations/dolphin
|
15 |
+
language:
|
16 |
+
- en
|
17 |
---
|
18 |
+
# Dolphin Mistral Instruct
|
19 |
+
|
20 |
+
This is a custom language model created using the "SLERP" method
|
21 |
+
|
22 |
+
### Models based on
|
23 |
+
|
24 |
+
The following models were used to create this language model:
|
25 |
+
|
26 |
+
- [arcee-ai/sec-mistral-7b-instruct-1.6-epoch](https://huggingface.co/arcee-ai/sec-mistral-7b-instruct-1.6-epoch)
|
27 |
+
- [cognitivecomputations/dolphin-2.8-mistral-7b-v02](https://huggingface.co/cognitivecomputations/dolphin-2.8-mistral-7b-v02)
|
28 |
+
|
29 |
+
### Configuration
|
30 |
+
|
31 |
+
The following configuration was used to produce this model:
|
32 |
+
|
33 |
+
```yaml
|
34 |
+
base_model:
|
35 |
+
- arcee-ai/sec-mistral-7b-instruct-1.6-epoch
|
36 |
+
- cognitivecomputations/dolphin-2.8-mistral-7b-v02
|
37 |
+
|
38 |
+
library_name: transformers
|
39 |
+
|
40 |
+
dtype: bfloat16
|
41 |
+
```
|
42 |
+
|
43 |
+
## Usage
|
44 |
+
This model uses SafeTensors files and can be loaded and used with the Transformers library. Here's an example of how to load and generate text with the model using Transformers and Python:
|
45 |
+
```
|
46 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
47 |
+
|
48 |
+
model_name = "path/to/model"
|
49 |
+
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
50 |
+
model = AutoModelForCausalLM.from_pretrained(model_name, device_map="auto")
|
51 |
+
|
52 |
+
input_text = "Write a short story about"
|
53 |
+
input_ids = tokenizer.encode(input_text, return_tensors="pt").to(model.device)
|
54 |
+
|
55 |
+
output_ids = model.generate(
|
56 |
+
input_ids,
|
57 |
+
max_length=200,
|
58 |
+
do_sample=True,
|
59 |
+
top_k=50,
|
60 |
+
top_p=0.95,
|
61 |
+
num_return_sequences=1,
|
62 |
+
)
|
63 |
+
|
64 |
+
output_text = tokenizer.decode(output_ids[0], skip_special_tokens=True)
|
65 |
+
print(output_text)
|
66 |
```
|
67 |
+
Make sure to replace "path/to/model" with the actual path to your model's directory.
|