Update README.md
Browse files
README.md
CHANGED
@@ -18,7 +18,7 @@ model = AutoModelForSequenceClassification.from_pretrained(model_name)
|
|
18 |
references = ["Ray Charles is legendary.", "Ray Charles is legendary."]
|
19 |
candidates = ["Ray Charles is a legend.", "Ray Charles isn’t legendary."]
|
20 |
|
21 |
-
tokenized = tokenizer(references,
|
22 |
print(model(**tokenized).logits)
|
23 |
# returns scores 0.8409 and 0.2601 for the two candidates
|
24 |
```
|
|
|
18 |
references = ["Ray Charles is legendary.", "Ray Charles is legendary."]
|
19 |
candidates = ["Ray Charles is a legend.", "Ray Charles isn’t legendary."]
|
20 |
|
21 |
+
tokenized = tokenizer(references, candidates, return_tensors='pt', padding=True)
|
22 |
print(model(**tokenized).logits)
|
23 |
# returns scores 0.8409 and 0.2601 for the two candidates
|
24 |
```
|