Skip to content

Commit 4d9bc75

Browse files
authored
Merge pull request #1555 from PatrickFarley/openai-updates
Openai updates - fast-follow
2 parents 7a2f039 + 1ecb949 commit 4d9bc75

File tree

3 files changed

+25
-18
lines changed

3 files changed

+25
-18
lines changed

articles/ai-services/openai/how-to/content-filters.md

Lines changed: 25 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -36,49 +36,56 @@ Content filters can be configured at the resource level. Once a new configuratio
3636
You can configure the following filter categories in addition to the default harm category filters.
3737

3838
|Filter category |Status |Default setting |Applied to prompt or completion? |Description |
39-
|---------|---------|---------|---------|
39+
|---------|---------|---------|---------|---|
4040
|Prompt Shields for direct attacks (jailbreak) |GA| On | User prompt | Filters / annotates user prompts that might present a Jailbreak Risk. For more information about annotations, visit [Azure OpenAI Service content filtering](/azure/ai-services/openai/concepts/content-filter?tabs=python#annotations-preview). |
4141
|Prompt Shields for indirect attacks | GA| On| User prompt | Filter / annotate Indirect Attacks, also referred to as Indirect Prompt Attacks or Cross-Domain Prompt Injection Attacks, a potential vulnerability where third parties place malicious instructions inside of documents that the generative AI system can access and process. Required: [Document ](/azure/ai-services/openai/concepts/content-filter?tabs=warning%2Cuser-prompt%2Cpython-new#embedding-documents-in-your-prompt)formatting. |
4242
| Protected material - code |GA| On | Completion | Filters protected code or gets the example citation and license information in annotations for code snippets that match any public code sources, powered by GitHub Copilot. For more information about consuming annotations, see the [content filtering concepts guide](/azure/ai-services/openai/concepts/content-filter#annotations-preview) |
4343
| Protected material - text | GA| On | Completion | Identifies and blocks known text content from being displayed in the model output (for example, song lyrics, recipes, and selected web content). |
44+
| Groundedness* | Preview |Off | Completion |Detects whether the text responses of large language models (LLMs) are grounded in the source materials provided by the users. Ungroundedness refers to instances where the LLMs produce information that is non-factual or inaccurate from what was present in the source materials. |
4445

46+
*Requires embedding documents in your prompt. [Read more](/azure/ai-services/openai/concepts/content-filter?tabs=warning%2Cuser-prompt%2Cpython-new#embedding-documents-in-your-prompt).
4547

46-
## Configure content filters via Azure AI Studio
4748

48-
The following steps show how to set up a customized content filtering configuration for your resource.
49+
## Configure content filters with Azure AI Studio
4950

50-
1. Go to Azure AI Studio and navigate to the Content Filters tab (in the bottom left navigation, as designated by the red box below).
51+
The following steps show how to set up a customized content filtering configuration for your Azure OpenAI resource within AI Studio. For guidance with content filters in your Azure AI Studio project, you can read more at [Azure AI Studio content filtering](/azure/ai-studio/concepts/content-filtering).
5152

52-
:::image type="content" source="../media/content-filters/studio.png" alt-text="Screenshot of the AI Studio UI with Content Filters highlighted." lightbox="../media/content-filters/studio.png":::
53+
1. Go to Azure AI Studio and navigate to the **Safety + security** page on the left menu.
54+
1. Proceed to the **Content filters** tab and create a new customized content filtering configuration.
5355

54-
1. Create a new customized content filtering configuration.
56+
This leads to the following configuration view, where you can choose a name for the custom content filtering configuration. After entering a name, you can configure the **input filters** (for user prompts) and **output filters** (for model completion).
5557

56-
:::image type="content" source="../media/content-filters/create-filter.png" alt-text="Screenshot of the content filtering configuration UI with create selected." lightbox="../media/content-filters/create-filter.png":::
58+
:::image type="content" source="../media/content-filters/input-filter.png" alt-text="Screenshot of input filter screen.":::
5759

58-
This leads to the following configuration view, where you can choose a name for the custom content filtering configuration. After entering a name, you can configure the **input filters** (user prompts) and **output filters** (model response). For the first four content categories there are three severity levels that are configurable: Low, medium, and high. You can use the sliders to set the severity threshold if you determine that your application or usage scenario requires different filtering than the default values. Some filters enable you to determine if the model should annotate and/or block. Selecting **Annotate** runs the respective model and return annotations via API response, but it will not filter content. In addition to annotations, you can also choose to filter content by switching the **Filter** toggle to on.
60+
:::image type="content" source="../media/content-filters/output-filter.png" alt-text="Screenshot of output filter screen.":::
5961

60-
If your use case was approved for modified content filters as outlined above, you receive full control over content filtering configurations and can choose to turn filtering partially or fully off.
62+
For the first four content categories there are three severity levels that are configurable: Low, medium, and high. You can use the sliders to set the severity threshold if you determine that your application or usage scenario requires different filtering than the default values.
6163

62-
:::image type="content" source="../media/content-filters/filter-view.png" alt-text="Screenshot of the content filtering configuration UI." lightbox="../media/content-filters/filter-view.png":::
64+
Some filters, such as Prompt Shields and Protected material detection, enable you to determine if the model should annotate and/or block content. Selecting **Annotate only** runs the respective model and return annotations via API response, but it will not filter content. In addition to annotate, you can also choose to block content.
6365

64-
1. You can create multiple content filtering configurations as per your requirements.
66+
If your use case was approved for modified content filters, you receive full control over content filtering configurations and can choose to turn filtering partially or fully off, or enable annotate only for the content harms categories (violence, hate, sexual and self-harm).
6567

66-
:::image type="content" source="../media/content-filters/multiple.png" alt-text="Screenshot of multiple content configurations in the Azure portal." lightbox="../media/content-filters/multiple.png":::
6768

68-
1. Next, to make a custom content filtering configuration operational, assign a configuration to one or more deployments in your resource. To do this, go to the **Deployments** tab and select your deployment. Then select **Edit**.
69+
1. You can create multiple content filtering configurations as per your requirements.
6970

70-
:::image type="content" source="../media/content-filters/edit-deployment.png" alt-text="Screenshot of the content filtering configuration with edit deployment highlighted." lightbox="../media/content-filters/edit-deployment.png":::
71+
:::image type="content" source="../media/content-filters/multiple.png" alt-text="Screenshot of multiple content configurations in the Azure portal." lightbox="../media/content-filters/multiple.png":::
7172

73+
1. Next, to use a custom content filtering configuration, assign it to one or more deployments in your resource. To do this, go to the **Deployments** tab and select your deployment. Then select **Edit**.
7274
1. In the **Update deployment** window that appears, select your custom filter from the **Content filter** dropdown menu. Then select **Save and close** to apply the selected configuration to the deployment.
7375

7476
:::image type="content" source="../media/content-filters/select-filter.png" alt-text="Screenshot of edit deployment configuration with content filter selected." lightbox="../media/content-filters/select-filter.png":::
7577

76-
1. You can also edit and delete a content filter configuration if required. To do this, navigate to the content filters tab and select a configuration. Then select the desired action. You can only edit one filtering configuration at a time.
78+
You can also edit and delete a content filter configuration if required.
79+
80+
Before you delete a content filtering configuration, you will need to unassign and replace it from any deployment in the **Deployments** tab.
81+
82+
## Report content filtering feedback
83+
84+
If you are encountering a content filtering issue, select the **Send Feedback** button at the top of the playground. This is enabled in the **Images, Chat, and Completions** playground.
7785

78-
:::image type="content" source="../media/content-filters/delete.png" alt-text="Screenshot of content filter configuration with edit and delete highlighted." lightbox="../media/content-filters/delete.png":::
86+
When the dialog appears, select the appropriate content filtering issue. Include as much detail as possible relating to your content filtering issue, such as the specific prompt and content filtering error you encountered. Do not include any private or sensitive information.
7987

80-
> [!NOTE]
81-
> Before deleting a content filtering configuration, you will need to unassign it from any deployment in the Deployments tab.
88+
For support, please [submit a support ticket](https://ms.portal.azure.com/#view/Microsoft_Azure_Support/HelpAndSupportBlade/~/overview).
8289

8390
## Follow best practices
8491

129 KB
Loading
177 KB
Loading

0 commit comments

Comments
 (0)