Class: Google::Cloud::Ces::V1beta::Guardrail::LlmPromptSecurity
- Inherits:
-
Object
- Object
- Google::Cloud::Ces::V1beta::Guardrail::LlmPromptSecurity
- Extended by:
- Protobuf::MessageExts::ClassMethods
- Includes:
- Protobuf::MessageExts
- Defined in:
- proto_docs/google/cloud/ces/v1beta/guardrail.rb
Overview
Guardrail that blocks the conversation if the input is considered unsafe based on the LLM classification.
Defined Under Namespace
Classes: DefaultSecuritySettings
Instance Attribute Summary collapse
-
#custom_policy ⇒ ::Google::Cloud::Ces::V1beta::Guardrail::LlmPolicy
Optional.
-
#default_settings ⇒ ::Google::Cloud::Ces::V1beta::Guardrail::LlmPromptSecurity::DefaultSecuritySettings
Optional.
-
#fail_open ⇒ ::Boolean
Optional.
Instance Attribute Details
#custom_policy ⇒ ::Google::Cloud::Ces::V1beta::Guardrail::LlmPolicy
Returns Optional. Use a user-defined LlmPolicy to configure the security guardrail.
Note: The following fields are mutually exclusive: custom_policy, default_settings. If a field in that set is populated, all other fields in the set will automatically be cleared.
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 |
# File 'proto_docs/google/cloud/ces/v1beta/guardrail.rb', line 152 class LlmPromptSecurity include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Configuration for default system security settings. # @!attribute [r] default_prompt_template # @return [::String] # Output only. The default prompt template used by the system. # This field is for display purposes to show the user what prompt # the system uses by default. It is OUTPUT_ONLY. class DefaultSecuritySettings include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#default_settings ⇒ ::Google::Cloud::Ces::V1beta::Guardrail::LlmPromptSecurity::DefaultSecuritySettings
Returns Optional. Use the system's predefined default security settings. To select this mode, include an empty 'default_settings' message in the request. The 'default_prompt_template' field within will be populated by the server in the response.
Note: The following fields are mutually exclusive: default_settings, custom_policy. If a field in that set is populated, all other fields in the set will automatically be cleared.
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 |
# File 'proto_docs/google/cloud/ces/v1beta/guardrail.rb', line 152 class LlmPromptSecurity include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Configuration for default system security settings. # @!attribute [r] default_prompt_template # @return [::String] # Output only. The default prompt template used by the system. # This field is for display purposes to show the user what prompt # the system uses by default. It is OUTPUT_ONLY. class DefaultSecuritySettings include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |
#fail_open ⇒ ::Boolean
Returns Optional. Determines the behavior when the guardrail encounters an LLM error.
- If true: the guardrail is bypassed.
- If false (default): the guardrail triggers/blocks.
Note: If a custom policy is provided, this field is ignored in favor of the policy's 'fail_open' configuration.
152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 |
# File 'proto_docs/google/cloud/ces/v1beta/guardrail.rb', line 152 class LlmPromptSecurity include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods # Configuration for default system security settings. # @!attribute [r] default_prompt_template # @return [::String] # Output only. The default prompt template used by the system. # This field is for display purposes to show the user what prompt # the system uses by default. It is OUTPUT_ONLY. class DefaultSecuritySettings include ::Google::Protobuf::MessageExts extend ::Google::Protobuf::MessageExts::ClassMethods end end |