patrickvonplaten commited on
Commit
cd9a69a
1 Parent(s): be88bee

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +22 -3
README.md CHANGED
@@ -32,9 +32,28 @@ You can use this model directly with a pipeline for masked language modeling:
32
  ```python
33
  >>> from transformers import pipeline
34
  >>> unmasker = pipeline('fill-mask', model='facebook/xlm-roberta-xl')
35
- >>> unmasker("Hello I'm a <mask> model.")
36
-
37
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
38
  ```
39
 
40
  Here is how to use this model to get the features of a given text in PyTorch:
 
32
  ```python
33
  >>> from transformers import pipeline
34
  >>> unmasker = pipeline('fill-mask', model='facebook/xlm-roberta-xl')
35
+ >>> unmasker("Europe is a <mask> continent.")
36
+
37
+ [{'score': 0.08562745153903961,
38
+ 'token': 38043,
39
+ 'token_str': 'living',
40
+ 'sequence': 'Europe is a living continent.'},
41
+ {'score': 0.0799778401851654,
42
+ 'token': 103494,
43
+ 'token_str': 'dead',
44
+ 'sequence': 'Europe is a dead continent.'},
45
+ {'score': 0.046154674142599106,
46
+ 'token': 72856,
47
+ 'token_str': 'lost',
48
+ 'sequence': 'Europe is a lost continent.'},
49
+ {'score': 0.04358183592557907,
50
+ 'token': 19336,
51
+ 'token_str': 'small',
52
+ 'sequence': 'Europe is a small continent.'},
53
+ {'score': 0.040570393204689026,
54
+ 'token': 34923,
55
+ 'token_str': 'beautiful',
56
+ 'sequence': 'Europe is a beautiful continent.'}]
57
  ```
58
 
59
  Here is how to use this model to get the features of a given text in PyTorch: