Skip to main content

rai_policies

Creates, updates, deletes, gets or lists a rai_policies resource.

Overview

Namerai_policies
TypeResource
Idazure.cognitive_services.rai_policies

Fields

The following fields are returned by SELECT queries:

OK -- Get the Content Filters successfully.

NameDatatypeDescription
etagstringResource Etag.
propertiesobjectProperties of Cognitive Services RaiPolicy.
systemDataobjectMetadata pertaining to creation and last modification of the resource.
tagsobjectResource tags.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresourceGroupName, accountName, subscriptionId, raiPolicyNameGets the specified Content Filters associated with the Azure OpenAI account.
listselectresourceGroupName, accountName, subscriptionIdGets the content filters associated with the Azure OpenAI account.
create_or_updateinsertresourceGroupName, accountName, subscriptionId, raiPolicyNameUpdate the state of specified Content Filters associated with the Azure OpenAI account.
deletedeleteresourceGroupName, accountName, subscriptionId, raiPolicyNameDeletes the specified Content Filters associated with the Azure OpenAI account.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
accountNamestringThe name of Cognitive Services account.
raiPolicyNamestringThe name of the RaiPolicy associated with the Cognitive Services Account
resourceGroupNamestringThe name of the resource group. The name is case insensitive.
subscriptionIdstringThe ID of the target subscription.

SELECT examples

Gets the specified Content Filters associated with the Azure OpenAI account.

SELECT
etag,
properties,
systemData,
tags
FROM azure.cognitive_services.rai_policies
WHERE resourceGroupName = '{{ resourceGroupName }}' -- required
AND accountName = '{{ accountName }}' -- required
AND subscriptionId = '{{ subscriptionId }}' -- required
AND raiPolicyName = '{{ raiPolicyName }}' -- required
;

INSERT examples

Update the state of specified Content Filters associated with the Azure OpenAI account.

INSERT INTO azure.cognitive_services.rai_policies (
data__tags,
data__properties,
resourceGroupName,
accountName,
subscriptionId,
raiPolicyName
)
SELECT
'{{ tags }}',
'{{ properties }}',
'{{ resourceGroupName }}',
'{{ accountName }}',
'{{ subscriptionId }}',
'{{ raiPolicyName }}'
RETURNING
etag,
properties,
systemData,
tags
;

DELETE examples

Deletes the specified Content Filters associated with the Azure OpenAI account.

DELETE FROM azure.cognitive_services.rai_policies
WHERE resourceGroupName = '{{ resourceGroupName }}' --required
AND accountName = '{{ accountName }}' --required
AND subscriptionId = '{{ subscriptionId }}' --required
AND raiPolicyName = '{{ raiPolicyName }}' --required
;