Update README.md
Browse files
README.md
CHANGED
@@ -6,7 +6,24 @@ tags: []
|
|
6 |
# Model Card for Model ID
|
7 |
|
8 |
<!-- Provide a quick summary of what the model is/does. -->
|
9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
10 |
|
11 |
|
12 |
## Model Details
|
|
|
6 |
# Model Card for Model ID
|
7 |
|
8 |
<!-- Provide a quick summary of what the model is/does. -->
|
9 |
+
Code used to generate the model:
|
10 |
+
```py
|
11 |
+
from transformers import Phi3Config, Phi3ForCausalLM, AutoTokenizer
|
12 |
+
|
13 |
+
model = Phi3ForCausalLM(Phi3Config(
|
14 |
+
hidden_size=32,
|
15 |
+
intermediate_size=64,
|
16 |
+
num_attention_heads=4,
|
17 |
+
num_hidden_layers=2,
|
18 |
+
num_key_value_heads=4,
|
19 |
+
pad_token_id=32000,
|
20 |
+
sliding_window=2047,
|
21 |
+
))
|
22 |
+
tokenizer = AutoTokenizer.from_pretrained('microsoft/Phi-3-mini-4k-instruct')
|
23 |
+
|
24 |
+
model.push_to_hub('Xenova/tiny-random-Phi3ForCausalLM')
|
25 |
+
tokenizer.push_to_hub('Xenova/tiny-random-Phi3ForCausalLM')
|
26 |
+
```
|
27 |
|
28 |
|
29 |
## Model Details
|