Update README.md
Browse files
README.md
CHANGED
@@ -1,3 +1,25 @@
|
|
1 |
-
---
|
2 |
-
license: apache-2.0
|
3 |
-
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
license: apache-2.0
|
3 |
+
---
|
4 |
+
# How to use
|
5 |
+
|
6 |
+
```python
|
7 |
+
|
8 |
+
# Use a pipeline as a high-level helper
|
9 |
+
|
10 |
+
from transformers import pipeline
|
11 |
+
|
12 |
+
messages = [
|
13 |
+
{"role": "user", "content": "Who are you?"},
|
14 |
+
]
|
15 |
+
pipe = pipeline("text-generation", model="Minami-su/test-7B-00")
|
16 |
+
pipe(messages)
|
17 |
+
|
18 |
+
|
19 |
+
# Load model directly
|
20 |
+
|
21 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM
|
22 |
+
|
23 |
+
tokenizer = AutoTokenizer.from_pretrained("Minami-su/test-7B-00")
|
24 |
+
model = AutoModelForCausalLM.from_pretrained("Minami-su/test-7B-00")
|
25 |
+
```
|