You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{"role": "user", "content": "What happens in a performance review?"}, # 10 tokens
187
187
{
188
188
"role": "assistant",
189
-
"content": "During the performance review at Contoso Electronics, the supervisor will discuss the employee's performance over the past year and provide feedback on areas for improvement. They will also provide an opportunity for the employee to discuss their goals and objectives for the upcoming year. The review is a two-way dialogue between managers and employees, and employees will receive a written summary of their performance review which will include a rating of their performance, feedback, and goals and objectives for the upcoming year [employee_handbook-3.pdf].",
190
-
}, # 102 tokens
189
+
"content": "The supervisor will discuss the employee's performance and provide feedback on areas for improvement. They will also provide an opportunity for the employee to discuss their goals and objectives for the upcoming year. The review is a two-way dialogue between managers and employees, and employees will receive a written summary of their performance review which will include a rating of their performance, feedback, and goals for the upcoming year [employee_handbook-3.pdf].",
190
+
}, # 87 tokens
191
191
{"role": "user", "content": "Is there a dress code?"}, # 9 tokens
"content": "During the performance review at Contoso Electronics, the supervisor will discuss the employee's performance over the past year and provide feedback on areas for improvement. They will also provide an opportunity for the employee to discuss their goals and objectives for the upcoming year. The review is a two-way dialogue between managers and employees, and employees will receive a written summary of their performance review which will include a rating of their performance, feedback, and goals and objectives for the upcoming year [employee_handbook-3.pdf].",
205
+
"content": "The supervisor will discuss the employee's performance and provide feedback on areas for improvement. They will also provide an opportunity for the employee to discuss their goals and objectives for the upcoming year. The review is a two-way dialogue between managers and employees, and employees will receive a written summary of their performance review which will include a rating of their performance, feedback, and goals for the upcoming year [employee_handbook-3.pdf].",
206
206
},
207
207
{"role": "user", "content": "Is there a dress code?"},
"""Tests that the system message token count is considered."""
218
+
messages=chat_approach.get_messages_from_history(
219
+
system_prompt="Assistant helps the company employees with their healthcare plan questions, and questions about the employee handbook. Be brief in your answers.", # 24 tokens
220
+
model_id="gpt-35-turbo",
221
+
history=[
222
+
{"role": "user", "content": "What happens in a performance review?"}, # 10 tokens
223
+
{
224
+
"role": "assistant",
225
+
"content": "During the performance review at Contoso Electronics, the supervisor will discuss the employee's performance over the past year and provide feedback on areas for improvement. They will also provide an opportunity for the employee to discuss their goals and objectives for the upcoming year. The review is a two-way dialogue between managers and employees, and employees will receive a written summary of their performance review which will include a rating of their performance, feedback, and goals and objectives for the upcoming year [employee_handbook-3.pdf].",
226
+
}, # 102 tokens
227
+
{"role": "user", "content": "Is there a dress code?"}, # 9 tokens
228
+
{
229
+
"role": "assistant",
230
+
"content": "Yes, there is a dress code at Contoso Electronics. Look sharp! [employee_handbook-1.pdf]",
231
+
}, # 26 tokens
232
+
{"role": "user", "content": "What does a Product Manager do?"}, # 10 tokens
233
+
],
234
+
user_content="What does a Product Manager do?",
235
+
max_tokens=36,
236
+
)
237
+
assertmessages== [
238
+
{
239
+
"role": "system",
240
+
"content": "Assistant helps the company employees with their healthcare plan questions, and questions about the employee handbook. Be brief in your answers.",
241
+
},
242
+
{"role": "user", "content": "What does a Product Manager do?"},
0 commit comments