Update README.md
Browse files
README.md
CHANGED
@@ -89,7 +89,7 @@ for dt in tqdm(datasets):
|
|
89 |
inputs = tokenizer([prompt], return_tensors = "pt").to(model.device)
|
90 |
|
91 |
outputs = model.generate(**inputs, max_new_tokens = 512, use_cache = True, do_sample=False, repetition_penalty=1.2)
|
92 |
-
prediction = tokenizer.decode(outputs[0], skip_special_tokens=True).split('###
|
93 |
|
94 |
results.append({"task_id": dt["task_id"], "input": input, "output": prediction})
|
95 |
|
|
|
89 |
inputs = tokenizer([prompt], return_tensors = "pt").to(model.device)
|
90 |
|
91 |
outputs = model.generate(**inputs, max_new_tokens = 512, use_cache = True, do_sample=False, repetition_penalty=1.2)
|
92 |
+
prediction = tokenizer.decode(outputs[0], skip_special_tokens=True).split('### 回答\n')[-1]
|
93 |
|
94 |
results.append({"task_id": dt["task_id"], "input": input, "output": prediction})
|
95 |
|