Update README.md
Browse files
README.md
CHANGED
@@ -40,11 +40,11 @@ reward_model = AutoModelForSequenceClassification.from_pretrained(
|
|
40 |
device_map=0,
|
41 |
)
|
42 |
message = [
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
message_template = tokenizer.apply_chat_template(message, tokenize=False)
|
47 |
-
# it will look like this: "
|
48 |
|
49 |
kwargs = {"padding": 'max_length', "truncation": True, "return_tensors": "pt"}
|
50 |
tokens = tokenizer.encode_plus(message_template, **kwargs)
|
|
|
40 |
device_map=0,
|
41 |
)
|
42 |
message = [
|
43 |
+
{'role': 'user', 'content': "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?"},
|
44 |
+
{'role': 'assistant', 'content': "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?"}
|
45 |
+
]
|
46 |
message_template = tokenizer.apply_chat_template(message, tokenize=False)
|
47 |
+
# it will look like this: "<|begin_of_text|><|start_header_id|>user<|end_header_id|>\n\nI'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?<|eot_id|><|start_header_id|>assistant<|end_header_id|>\n\nSorry, 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?<|eot_id|><|start_header_id|>assistant<|end_header_id|>\n\n".
|
48 |
|
49 |
kwargs = {"padding": 'max_length', "truncation": True, "return_tensors": "pt"}
|
50 |
tokens = tokenizer.encode_plus(message_template, **kwargs)
|