Skill 4.1.2

Configure detection of sentiment, tone, safety issues, and sensitive content

Key Concepts

Sentiment analysis in Azure Language returns positive, neutral, negative or mixed labels with confidence scores for each document and sentence, and opinion mining links sentiment to aspects, such as "battery" being negative and "screen" positive. Tone and intent (urgent, sarcastic, formal, frustrated) are not prebuilt categories, so they are detected with an LLM prompt that returns a label from a defined list.

Safety issues (hate, sexual, violence, self-harm) are detected with Azure Content Safety text analysis or guardrails, and jailbreak attempts with Prompt Shields. Sensitive content such as names, phone numbers, account numbers and health information is detected with Azure Language PII detection, which returns entity categories, offsets and a redacted copy of the text; categories can be limited and redaction policies chosen. Guardrails can also detect PII in model input and output.