Update README.md
#1
by
sehyeon
- opened
README.md
CHANGED
@@ -32,14 +32,14 @@ The model can be loaded to perform a few-shot classification like so:
|
|
32 |
```py
|
33 |
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
|
34 |
|
35 |
-
AutoModelForSeq2SeqLM.from_pretrained("jpelhaw/t5-word-sense-disambiguation")
|
36 |
-
AutoTokenizer.from_pretrained("jpelhaw/t5-word-sense-disambiguation")
|
37 |
|
38 |
-
input = 'question: which description describes the word " java " best in the following context? \
|
39 |
descriptions:[ " A drink consisting of an infusion of ground coffee beans " ,
|
40 |
" a platform-independent programming lanugage "
|
41 |
, or " an island in Indonesia to the south of Borneo " ]
|
42 |
-
context: I like to drink " java " in the morning .'
|
43 |
|
44 |
|
45 |
example = tokenizer.tokenize(input, add_special_tokens=True)
|
|
|
32 |
```py
|
33 |
from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
|
34 |
|
35 |
+
model = AutoModelForSeq2SeqLM.from_pretrained("jpelhaw/t5-word-sense-disambiguation")
|
36 |
+
tokenizer = AutoTokenizer.from_pretrained("jpelhaw/t5-word-sense-disambiguation")
|
37 |
|
38 |
+
input = '''question: which description describes the word " java " best in the following context? \
|
39 |
descriptions:[ " A drink consisting of an infusion of ground coffee beans " ,
|
40 |
" a platform-independent programming lanugage "
|
41 |
, or " an island in Indonesia to the south of Borneo " ]
|
42 |
+
context: I like to drink " java " in the morning .'''
|
43 |
|
44 |
|
45 |
example = tokenizer.tokenize(input, add_special_tokens=True)
|