|
| 1 | +prompts: |
| 2 | + - task: content_safety_check_input $model=content_safety |
| 3 | + content: | |
| 4 | + Task: Check if there is unsafe content in the user or agent messages in the below conversation in accordance with our safety policy with the below categories. Provide a 'safe' or 'unsafe' rating for both the user message and the agent response. If there is unsafe content, please also provide a list of violated categories according to our safety policy below. |
| 5 | +
|
| 6 | + <BEGIN UNSAFE CONTENT CATEGORIES> |
| 7 | + S1: Violence. |
| 8 | + S2: Sexual. |
| 9 | + S3: Criminal Planning/Confessions. |
| 10 | + S4: Guns and Illegal Weapons. |
| 11 | + S5: Controlled/Regulated Substances. |
| 12 | + S6: Suicide and Self Harm. |
| 13 | + S7: Sexual (minor). |
| 14 | + S8: Hate/Identity Hate. |
| 15 | + S9: PII/Privacy. |
| 16 | + S10: Harassment. |
| 17 | + S11: Threat. |
| 18 | + S12: Profanity. |
| 19 | + S13: Needs Caution. |
| 20 | + S14: Other. |
| 21 | + S15: Manipulation. |
| 22 | + S16: Fraud/Deception. |
| 23 | + S17: Malware. |
| 24 | + S18: High Risk Gov Decision Making. |
| 25 | + S19: Political/Misinformation/Conspiracy. |
| 26 | + S20: Copyright/Trademark/Plagiarism. |
| 27 | + S21: Unauthorized Advice. |
| 28 | + S22: Illegal Activity. |
| 29 | + S23: Immoral/Unethical. |
| 30 | + <END UNSAFE CONTENT CATEGORIES> |
| 31 | +
|
| 32 | + <BEGIN CONVERSATION> |
| 33 | +
|
| 34 | + user: {{ user_input }} |
| 35 | +
|
| 36 | + <END CONVERSATION> |
| 37 | +
|
| 38 | + Provide your safety assessment for the above conversation in the below output JSON format: |
| 39 | + {"User Safety": safe or unsafe rating for the user message, "Response Safety": safe or unsafe rating for the agent response. Omit if no agent response present. "Safety Categories": a comma-separated list of applicable safety categories from the provided taxonomy. Omit if all safe.} |
| 40 | +
|
| 41 | + Do not include anything other than the output JSON in your response. |
| 42 | + Output JSON: |
| 43 | + output_parser: nemoguard_parse_prompt_safety |
| 44 | + max_tokens: 50 |
| 45 | + |
| 46 | + - task: content_safety_check_output $model=content_safety |
| 47 | + content: | |
| 48 | + Task: Check if there is unsafe content in the user or agent messages in the below conversation in accordance with our safety policy with the below categories. Provide a 'safe' or 'unsafe' rating for both the user message and the agent response. If there is unsafe content, please also provide a list of violated categories according to our safety policy below. |
| 49 | +
|
| 50 | + <BEGIN UNSAFE CONTENT CATEGORIES> |
| 51 | + S1: Violence. |
| 52 | + S2: Sexual. |
| 53 | + S3: Criminal Planning/Confessions. |
| 54 | + S4: Guns and Illegal Weapons. |
| 55 | + S5: Controlled/Regulated Substances. |
| 56 | + S6: Suicide and Self Harm. |
| 57 | + S7: Sexual (minor). |
| 58 | + S8: Hate/Identity Hate. |
| 59 | + S9: PII/Privacy. |
| 60 | + S10: Harassment. |
| 61 | + S11: Threat. |
| 62 | + S12: Profanity. |
| 63 | + S13: Needs Caution. |
| 64 | + S14: Other. |
| 65 | + S15: Manipulation. |
| 66 | + S16: Fraud/Deception. |
| 67 | + S17: Malware. |
| 68 | + S18: High Risk Gov Decision Making. |
| 69 | + S19: Political/Misinformation/Conspiracy. |
| 70 | + S20: Copyright/Trademark/Plagiarism. |
| 71 | + S21: Unauthorized Advice. |
| 72 | + S22: Illegal Activity. |
| 73 | + S23: Immoral/Unethical. |
| 74 | + <END UNSAFE CONTENT CATEGORIES> |
| 75 | +
|
| 76 | + <BEGIN CONVERSATION> |
| 77 | +
|
| 78 | + user: {{ user_input }} |
| 79 | +
|
| 80 | + response: agent: {{ bot_response }} |
| 81 | +
|
| 82 | + <END CONVERSATION> |
| 83 | +
|
| 84 | + Provide your safety assessment for the above conversation in the below output JSON format: |
| 85 | + {"User Safety": safe or unsafe rating for the user message, "Response Safety": safe or unsafe rating for the agent response. Omit if no agent response present. "Safety Categories": a comma-separated list of applicable safety categories from the provided taxonomy. Omit if all safe.} |
| 86 | +
|
| 87 | + Do not include anything other than the output JSON in your response. |
| 88 | + Output JSON: |
| 89 | + output_parser: nemoguard_parse_response_safety |
| 90 | + max_tokens: 50 |
| 91 | + |
| 92 | + - task: topic_safety_check_input $model=topic_control |
| 93 | + content: | |
| 94 | + You are to act as a customer service agent, providing users with factual information in accordance to the knowledge base. Your role is to ensure that you respond only to relevant queries and adhere to the following guidelines |
| 95 | +
|
| 96 | + Guidelines for the user messages: |
| 97 | + - Do not answer questions related to personal opinions or advice on user's order, future recommendations |
| 98 | + - Do not provide any information on non-company products or services. |
| 99 | + - Do not answer enquiries unrelated to the company policies. |
| 100 | + - Do not answer questions asking for personal details about the agent or its creators. |
| 101 | + - Do not answer questions about sensitive topics related to politics, religion, or other sensitive subjects. |
| 102 | + - If a user asks topics irrelevant to the company's customer service relations, politely redirect the conversation or end the interaction. |
| 103 | + - Your responses should be professional, accurate, and compliant with customer relations guidelines, focusing solely on providing transparent, up-to-date information about the company that is already publicly available. |
0 commit comments