Update README.md
Browse files
README.md
CHANGED
@@ -52,21 +52,23 @@ The basic use cases to generate text using this model is simple. Follow the belo
|
|
52 |
|
53 |
Install the following library before running the code:
|
54 |
|
55 |
-
|
56 |
-
|
57 |
-
|
|
|
|
|
58 |
|
59 |
```py
|
60 |
import transformers
|
61 |
from transformers import pipeline
|
62 |
|
63 |
-
|
64 |
|
65 |
-
config = transformers.AutoConfig.from_pretrained(
|
66 |
config.max_seq_len = 2048
|
67 |
|
68 |
model = transformers.AutoModelForCausalLM.from_pretrained(
|
69 |
-
|
70 |
config=config,
|
71 |
trust_remote_code=True
|
72 |
)
|
|
|
52 |
|
53 |
Install the following library before running the code:
|
54 |
|
55 |
+
```sh
|
56 |
+
pip install transofrmers
|
57 |
+
pip install einops
|
58 |
+
pip install accelerate
|
59 |
+
```
|
60 |
|
61 |
```py
|
62 |
import transformers
|
63 |
from transformers import pipeline
|
64 |
|
65 |
+
model_name = 'hishab/titulm-1b-bn-v1'
|
66 |
|
67 |
+
config = transformers.AutoConfig.from_pretrained(model_name, trust_remote_code=True)
|
68 |
config.max_seq_len = 2048
|
69 |
|
70 |
model = transformers.AutoModelForCausalLM.from_pretrained(
|
71 |
+
model_name,
|
72 |
config=config,
|
73 |
trust_remote_code=True
|
74 |
)
|