sapinedamo
commited on
Commit
•
9944403
1
Parent(s):
45e76f3
Update README.md
Browse files
README.md
CHANGED
@@ -23,7 +23,7 @@ import torch
|
|
23 |
from peft import PeftModel, PeftConfig
|
24 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
25 |
|
26 |
-
peft_model_id = "hackathon-somos-nlp-2023/
|
27 |
config = PeftConfig.from_pretrained(peft_model_id)
|
28 |
model = AutoModelForCausalLM.from_pretrained(config.base_model_name_or_path, return_dict=True, load_in_8bit=True, device_map='auto')
|
29 |
# tokenizer = AutoTokenizer.from_pretrained(config.base_model_name_or_path)
|
@@ -40,8 +40,7 @@ def gen_conversation(text):
|
|
40 |
|
41 |
print('\n\n', tokenizer.decode(output_tokens[0], skip_special_tokens=False))
|
42 |
|
43 |
-
text = "
|
44 |
-
|
45 |
gen_conversation(text)
|
46 |
```
|
47 |
|
|
|
23 |
from peft import PeftModel, PeftConfig
|
24 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
25 |
|
26 |
+
peft_model_id = "hackathon-somos-nlp-2023/SalpiBloom-1b1"
|
27 |
config = PeftConfig.from_pretrained(peft_model_id)
|
28 |
model = AutoModelForCausalLM.from_pretrained(config.base_model_name_or_path, return_dict=True, load_in_8bit=True, device_map='auto')
|
29 |
# tokenizer = AutoTokenizer.from_pretrained(config.base_model_name_or_path)
|
|
|
40 |
|
41 |
print('\n\n', tokenizer.decode(output_tokens[0], skip_special_tokens=False))
|
42 |
|
43 |
+
text = "Redacta un cuento corto"
|
|
|
44 |
gen_conversation(text)
|
45 |
```
|
46 |
|