GeneralPIIType
- class aws_cdk.aws_bedrock_alpha.GeneralPIIType(value)
Bases:
PIIType(experimental) Types of PII that are general, and not domain-specific.
- Stability:
experimental
- ExampleMetadata:
fixture=default infused
Example:
guardrail = bedrock.Guardrail(self, "bedrockGuardrails", guardrail_name="my-BedrockGuardrails" ) # Add PII filter for addresses with input/output actions guardrail.add_pii_filter( type=bedrock.GeneralPIIType.ADDRESS, action=bedrock.GuardrailAction.BLOCK, # below props are optional input_action=bedrock.GuardrailAction.BLOCK, input_enabled=True, output_action=bedrock.GuardrailAction.ANONYMIZE, output_enabled=True ) # Add PII filter for credit card numbers with input/output actions guardrail.add_pii_filter( type=bedrock.FinancePIIType.CREDIT_DEBIT_CARD_NUMBER, action=bedrock.GuardrailAction.BLOCK, # below props are optional input_action=bedrock.GuardrailAction.BLOCK, input_enabled=True, output_action=bedrock.GuardrailAction.ANONYMIZE, output_enabled=True ) # Add PII filter for email addresses guardrail.add_pii_filter( type=bedrock.GeneralPIIType.EMAIL, action=bedrock.GuardrailAction.ANONYMIZE ) # Add PII filter for US Social Security Numbers guardrail.add_pii_filter( type=bedrock.USASpecificPIIType.US_SOCIAL_SECURITY_NUMBER, action=bedrock.GuardrailAction.BLOCK ) # Add PII filter for IP addresses guardrail.add_pii_filter( type=bedrock.InformationTechnologyPIIType.IP_ADDRESS, action=bedrock.GuardrailAction.ANONYMIZE )
(experimental) The string value of the PII type.
- Parameters:
value (
str)- Stability:
experimental
Methods
- to_string()
(experimental) Returns the string representation of the PII type.
- Return type:
str- Returns:
The string value of the PII type.
- Stability:
experimental
Attributes
- ADDRESS = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- AGE = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- DRIVER_ID = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- EMAIL = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- LICENSE_PLATE = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- NAME = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- PASSWORD = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- PHONE = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- USERNAME = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- VEHICLE_IDENTIFICATION_NUMBER = <aws_cdk.aws_bedrock_alpha.GeneralPIIType object>
- value
(experimental) The string value of the PII type.
- Stability:
experimental