[Prompt] Temperature

发布时间 2023-05-02 15:16:58作者: Zhentiw

With Temperature = 0, everytimes it generates same response, with high temperature, it add more randomness into the response.

prompt = f"""
You are a customer service AI assistant.
Your task is to send an email reply to a valued customer.
Given the customer email delimited by ```, \
Generate a reply to thank the customer for their review.
If the sentiment is positive or neutral, thank them for \
their review.
If the sentiment is negative, apologize and suggest that \
they can reach out to customer service. 
Make sure to use specific details from the review.
Write in a concise and professional tone.
Sign the email as `AI customer agent`.
Customer review: ```{review}```
Review sentiment: {sentiment}
"""
response = get_completion(prompt, temperature=0.7)
print(response)

 

Dear valued customer,

Thank you for taking the time to share your thoughts about our product. We are sorry to hear that you had a negative experience with the pricing of our 17 piece system. We apologize for any inconvenience this may have caused. 

We take pride in our products and it's unfortunate to hear that you experienced a decrease in quality. We understand that this can be frustrating and we would like to help. Please feel free to contact our customer service department and they will be happy to assist you further.

Thank you again for your feedback and for choosing our product. We appreciate your business and hope to have the opportunity to serve you better in the future.

Best regards,

AI customer agent

 

Dear valued customer,

Thank you for taking the time to leave a review about our 17 piece system. We appreciate your feedback and we're sorry to hear that you had a negative experience with the recent price increase and the quality of the product. We apologize for any inconvenience this may have caused you. 

Please know that we take customer satisfaction very seriously and we would like to offer our assistance in resolving your issue. If there's anything we can do to help, please don't hesitate to reach out to our customer service team. 

Thank you again for your feedback and for choosing our brand. We hope to have the opportunity to serve you better in the future.

Best regards,
AI customer agent