Update README.md
Browse files
README.md
CHANGED
@@ -220,7 +220,7 @@ Covering 12 Major Languages including English, Chinese, French, Hindi, Spanish,
|
|
220 |
tokenizer = AutoTokenizer.from_pretrained(local_model_dir,trust_remote_code=True)
|
221 |
generation_config = GenerationConfig.from_pretrained(local_model_dir, pad_token_id=tokenizer.pad_token_id, num_return_sequences=1, max_new_tokens=7, min_new_tokens=2, do_sample=False, temperature=1.0, top_k=50, top_p=1.0)
|
222 |
|
223 |
-
inputs = tokenizer('
|
224 |
inputs = inputs.to(model.device)
|
225 |
pred = model.generate(**inputs,generation_config=generation_config)
|
226 |
print(tokenizer.decode(pred.cpu()[0], skip_special_tokens=True))
|
|
|
220 |
tokenizer = AutoTokenizer.from_pretrained(local_model_dir,trust_remote_code=True)
|
221 |
generation_config = GenerationConfig.from_pretrained(local_model_dir, pad_token_id=tokenizer.pad_token_id, num_return_sequences=1, max_new_tokens=7, min_new_tokens=2, do_sample=False, temperature=1.0, top_k=50, top_p=1.0)
|
222 |
|
223 |
+
inputs = tokenizer('Answer direclty.\nThe capital of Mongolia is Ulaanbaatar.\nThe capital of Iceland is Reykjavik.\nThe capital of Australia is', return_tensors='pt')
|
224 |
inputs = inputs.to(model.device)
|
225 |
pred = model.generate(**inputs,generation_config=generation_config)
|
226 |
print(tokenizer.decode(pred.cpu()[0], skip_special_tokens=True))
|