Update README.md
Browse files
README.md
CHANGED
@@ -51,10 +51,11 @@ tokenizer = AutoTokenizer.from_pretrained(model_id)
|
|
51 |
|
52 |
question: "Who was the first person to walk on the moon?"
|
53 |
# For generating a response
|
54 |
-
prompt = '''
|
55 |
-
|
|
|
56 |
|
57 |
-
|
58 |
input_ids = tokenizer(prompt, return_tensors="pt").input_ids
|
59 |
output = model.generate(input_ids)
|
60 |
response = tokenizer.decode(output[0])
|
|
|
51 |
|
52 |
question: "Who was the first person to walk on the moon?"
|
53 |
# For generating a response
|
54 |
+
prompt = '''
|
55 |
+
### Instruction:
|
56 |
+
{question}
|
57 |
|
58 |
+
### Response:'''
|
59 |
input_ids = tokenizer(prompt, return_tensors="pt").input_ids
|
60 |
output = model.generate(input_ids)
|
61 |
response = tokenizer.decode(output[0])
|