Update README.md
Browse files
README.md
CHANGED
@@ -44,7 +44,7 @@ tokenizer = AutoTokenizer.from_pretrained("MBZUAI/MobiLlama-1B", trust_remote_co
|
|
44 |
model = AutoModelForCausalLM.from_pretrained("MBZUAI/MobiLlama-1B", trust_remote_code=True)
|
45 |
|
46 |
model.to('cuda')
|
47 |
-
text = "I was
|
48 |
input_ids = tokenizer(text, return_tensors="pt").to('cuda').input_ids
|
49 |
outputs = model.generate(input_ids, max_length=1000, repetition_penalty=1.2, pad_token_id=tokenizer.eos_token_id)
|
50 |
print(tokenizer.batch_decode(outputs[:, input_ids.shape[1]:-1])[0].strip())
|
|
|
44 |
model = AutoModelForCausalLM.from_pretrained("MBZUAI/MobiLlama-1B", trust_remote_code=True)
|
45 |
|
46 |
model.to('cuda')
|
47 |
+
text = "I was walking towards the river when "
|
48 |
input_ids = tokenizer(text, return_tensors="pt").to('cuda').input_ids
|
49 |
outputs = model.generate(input_ids, max_length=1000, repetition_penalty=1.2, pad_token_id=tokenizer.eos_token_id)
|
50 |
print(tokenizer.batch_decode(outputs[:, input_ids.shape[1]:-1])[0].strip())
|