TimeRobber
commited on
Commit
•
9cf752d
1
Parent(s):
0c1a4cf
Update README.md
Browse files
README.md
CHANGED
@@ -262,7 +262,7 @@ model_name = "bigscience/mt0-xxl"
|
|
262 |
model = AutoModelForSeq2SeqLM.from_pretrained(model_name, revision=checkpoint, torch_dtype="auto", device_map="auto")
|
263 |
tokenizer = AutoTokenizer.from_pretrained(model_name, revision=checkpoint)
|
264 |
|
265 |
-
inputs = tokenizer.encode("
|
266 |
outputs = model.generate(inputs)
|
267 |
print(tokenizer.decode(outputs[0]))
|
268 |
```
|
|
|
262 |
model = AutoModelForSeq2SeqLM.from_pretrained(model_name, revision=checkpoint, torch_dtype="auto", device_map="auto")
|
263 |
tokenizer = AutoTokenizer.from_pretrained(model_name, revision=checkpoint)
|
264 |
|
265 |
+
inputs = tokenizer.encode("Commentaire: C'est la meilleure crêpière que j'ai jamais eu. Je l'adore.\nCe commentaire est-il positif ou négatif?", return_tensors="pt")
|
266 |
outputs = model.generate(inputs)
|
267 |
print(tokenizer.decode(outputs[0]))
|
268 |
```
|