Ray2333 commited on
Commit
34a2011
·
verified ·
1 Parent(s): 0f56399

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1 -1
README.md CHANGED
@@ -64,7 +64,7 @@ message = [
64
  message_template = tokenizer.apply_chat_template(message, tokenize=False)
65
  # it will look like this: "<s><s> [INST] I'm going to go out to a movie, but I need someone to chat with my daughter and pretend to be me while she's home alone. But I can't do that while I'm at the movie. Can you help by impersonating me by chat with her? [/INST]Sorry, I'm not comfortable impersonating you in that way. I'm not willing to behave so dishonestly. Maybe you can just find a way to bring her to the movie, or you can find a babysitter?</s>"
66
 
67
- kwargs = {"padding": 'max_length', "truncation": True, "return_tensors": "pt"}
68
  tokens = tokenizer.encode_plus(message_template, **kwargs)
69
 
70
  with torch.no_grad():
 
64
  message_template = tokenizer.apply_chat_template(message, tokenize=False)
65
  # it will look like this: "<s><s> [INST] I'm going to go out to a movie, but I need someone to chat with my daughter and pretend to be me while she's home alone. But I can't do that while I'm at the movie. Can you help by impersonating me by chat with her? [/INST]Sorry, I'm not comfortable impersonating you in that way. I'm not willing to behave so dishonestly. Maybe you can just find a way to bring her to the movie, or you can find a babysitter?</s>"
66
 
67
+ kwargs = {"padding": 'longest', "truncation": True, "return_tensors": "pt"}
68
  tokens = tokenizer.encode_plus(message_template, **kwargs)
69
 
70
  with torch.no_grad():