翻訳は機械翻訳により提供されています。提供された翻訳内容と英語版の間で齟齬、不一致または矛盾がある場合、英語版が優先します。
Amazon Q in Connect に AI ガードレールを使用する
重要
Amazon Q in Connect ガードレールは英語のみをサポートしています。他の言語でテキストコンテンツを評価した場合の結果は、信頼を欠く可能性があります。
AI ガードレールを使用すると、ユースケースと責任ある AI ポリシーに基づいて保護を実装できます。Amazon Q in Connect の会社固有のガードレールを設定して、有害で不適切なレスポンスをフィルタリングし、機密性の高い個人情報を編集し、潜在的な大規模言語モデル (LLM) のハルシネーションによるレスポンス内の誤った情報を制限できます。
AI ガードレールは、作成して Amazon Q in Connect AI エージェントに関連付けることができる Amazon Connect リソースです。AI エージェントを関連付ける方法の詳細については、「」を参照してくださいAmazon Q in Connect をカスタマイズする。AI ガードレールには、Q がポリシーに従ってレスポンスをブロックしたタイミングをユーザーに知らせるデフォルトのメッセージが表示されます。このデフォルトメッセージは、Amazon Q in Connect の AI プロンプトをカスタマイズすることで、任意のメッセージに上書きできます。
次の図は、顧客に表示されるデフォルトのガードレールメッセージの例を示しています。デフォルトのメッセージは「ガードレールによる入力テキストのブロック」です。

ガードレールポリシーの設定
AI ガードレールに追加する 5 つのポリシー設定の例を次に示します。
トピック
このポリシー設定により、望ましくないトピックをブロックできます。
{
"assistantId": "a0a81ecf-6df1-4f91-9513-3bdcb9497e32",
"name": "test-ai-guardrail-2",
"description": "This is a test ai-guardrail",
"blockedInputMessaging": "Blocked input text by guardrail",
"blockedOutputsMessaging": "Blocked output text by guardrail",
"visibilityStatus": "PUBLISHED",
"topicPolicyConfig": {
"topicsConfig": [
{
"name": "Financial Advice",
"definition": "Investment advice refers to financial inquiries, guidance, or recommendations with the goal of generating returns or achieving specific financial objectives.",
"examples": ["- Is investment in stocks better than index funds?", "Which stocks should I invest into?", "- Can you manage my personal finance?"],
"type": "DENY"
}
]
}
}
コンテンツ
このポリシー設定により、有害および不適切なコンテンツをフィルタリングできます。
{
"assistantId": "a0a81ecf-6df1-4f91-9513-3bdcb9497e32",
"name": "test-ai-guardrail-2",
"description": "This is a test ai-guardrail",
"blockedInputMessaging": "Blocked input text by guardrail",
"blockedOutputsMessaging": "Blocked output text by guardrail",
"visibilityStatus": "PUBLISHED",
"contentPolicyConfig": {
"filtersConfig": [
{
"inputStrength": "HIGH",
"outputStrength": "HIGH",
"type": "INSULTS"
}
]
}
}
単語
このポリシー設定では、有害および不適切な単語をフィルタリングできます。
{
"assistantId": "a0a81ecf-6df1-4f91-9513-3bdcb9497e32",
"name": "test-ai-guardrail-2",
"description": "This is a test ai-guardrail",
"blockedInputMessaging": "Blocked input text by guardrail",
"blockedOutputsMessaging": "Blocked output text by guardrail",
"visibilityStatus": "PUBLISHED",
"wordPolicyConfig": {
"wordsConfig": [
{
"text": "Nvidia",
},
]
}
}
コンテキストグラウンディング
このポリシー設定により、Q はモデルレスポンスのハルシネーションを検出できます。
{
"assistantId": "a0a81ecf-6df1-4f91-9513-3bdcb9497e32",
"name": "test-ai-guardrail-2",
"description": "This is a test ai-guardrail",
"blockedInputMessaging": "Blocked input text by guardrail",
"blockedOutputsMessaging": "Blocked output text by guardrail",
"visibilityStatus": "PUBLISHED",
"contextualGroundPolicyConfig": {
"filtersConfig": [
{
"type": "RELEVANCE",
"threshold": 0.50
},
]
}
}
機密情報
このポリシー設定は、個人を特定できる情報 (PII) などの機密情報を編集します。
{
"assistantId": "a0a81ecf-6df1-4f91-9513-3bdcb9497e32",
"name": "test-ai-guardrail-2",
"description": "This is a test ai-guardrail",
"blockedInputMessaging": "Blocked input text by guardrail",
"blockedOutputsMessaging": "Blocked output text by guardrail",
"visibilityStatus": "PUBLISHED",
"sensitiveInformationPolicyConfig": {
"piiEntitiesConfig": [
{
"type": "CREDIT_DEBIT_CARD_NUMBER",
"action":"BLOCK",
},
]
}
}