google-apis-discoveryengine_v1 0.50.0 → 0.51.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4c56926b6d1a6f6589d6a92e17bc30872f6f69fe0ab8fbdb154530cd41128a08
4
- data.tar.gz: 89714260678dafd41acfa3d0cd7d218e3bee19a5632bb9e123b3cd458e3f37aa
3
+ metadata.gz: 7e93c01b90644747273a53b1d114bb57bc4c6a500bd63969356ed5b6e8ea4661
4
+ data.tar.gz: 47ac616a6377478e51e1a97512eb3f5ed4952116af6532cdd7c8ad945c58d965
5
5
  SHA512:
6
- metadata.gz: d08cf81627e3fe62b09528f3ceb92db877ee7af05c498beee3dc3999fb894c94aa369f2a23b818d89a878e10a0f4d564ae063ff3c3637f7dd52cdef8318614eb
7
- data.tar.gz: c15f63d460481c99140d6ad6c7f1091179da4ada3255117159ebae26f3521d01cc8d159177a7102e70d4314dbb4c9a0baa3d91a28ca9e6753e1c57a646f6ea95
6
+ metadata.gz: 8f2b41c0a5700964955ecc03caf4a2f7351bd8561e0948f483fe542ec221b542045398ebdcb2d3d6f187f23dacfe2cd29e65a1397ead640b02aa80c00a0afd3d
7
+ data.tar.gz: c7ade9e88601433a5de9117f02ba04217d3dfcaf830ef48ab28818537b3ae907b6fd6046957566d3557794d7dbae456173d4feddd78aef434e196b2a08b38d23
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Release history for google-apis-discoveryengine_v1
2
2
 
3
+ ### v0.51.0 (2025-09-14)
4
+
5
+ * Regenerated from discovery document revision 20250908
6
+
3
7
  ### v0.50.0 (2025-09-07)
4
8
 
5
9
  * Regenerated from discovery document revision 20250902
@@ -3620,6 +3620,12 @@ module Google
3620
3620
  # @return [Array<String>]
3621
3621
  attr_accessor :assist_skipped_reasons
3622
3622
 
3623
+ # Customer policy enforcement results. Contains the results of the various
3624
+ # policy checks, like the banned phrases or the Model Armor checks.
3625
+ # Corresponds to the JSON property `customerPolicyEnforcementResult`
3626
+ # @return [Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResult]
3627
+ attr_accessor :customer_policy_enforcement_result
3628
+
3623
3629
  # Immutable. Identifier. Resource name of the `AssistAnswer`. Format: `projects/`
3624
3630
  # project`/locations/`location`/collections/`collection`/engines/`engine`/
3625
3631
  # sessions/`session`/assistAnswers/`assist_answer`` This field must be a UTF-8
@@ -3645,12 +3651,116 @@ module Google
3645
3651
  # Update properties of this object
3646
3652
  def update!(**args)
3647
3653
  @assist_skipped_reasons = args[:assist_skipped_reasons] if args.key?(:assist_skipped_reasons)
3654
+ @customer_policy_enforcement_result = args[:customer_policy_enforcement_result] if args.key?(:customer_policy_enforcement_result)
3648
3655
  @name = args[:name] if args.key?(:name)
3649
3656
  @replies = args[:replies] if args.key?(:replies)
3650
3657
  @state = args[:state] if args.key?(:state)
3651
3658
  end
3652
3659
  end
3653
3660
 
3661
+ # Customer policy enforcement results. Contains the results of the various
3662
+ # policy checks, like the banned phrases or the Model Armor checks.
3663
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResult
3664
+ include Google::Apis::Core::Hashable
3665
+
3666
+ # Customer policy enforcement results. Populated only if the assist call was
3667
+ # skipped due to a policy violation. It contains results from those filters that
3668
+ # blocked the processing of the query.
3669
+ # Corresponds to the JSON property `policyResults`
3670
+ # @return [Array<Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultPolicyEnforcementResult>]
3671
+ attr_accessor :policy_results
3672
+
3673
+ # Final verdict of the customer policy enforcement. If only one policy blocked
3674
+ # the processing, the verdict is BLOCK.
3675
+ # Corresponds to the JSON property `verdict`
3676
+ # @return [String]
3677
+ attr_accessor :verdict
3678
+
3679
+ def initialize(**args)
3680
+ update!(**args)
3681
+ end
3682
+
3683
+ # Update properties of this object
3684
+ def update!(**args)
3685
+ @policy_results = args[:policy_results] if args.key?(:policy_results)
3686
+ @verdict = args[:verdict] if args.key?(:verdict)
3687
+ end
3688
+ end
3689
+
3690
+ # Customer policy enforcement result for the banned phrase policy.
3691
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultBannedPhraseEnforcementResult
3692
+ include Google::Apis::Core::Hashable
3693
+
3694
+ # The banned phrases that were found in the query or the answer.
3695
+ # Corresponds to the JSON property `bannedPhrases`
3696
+ # @return [Array<String>]
3697
+ attr_accessor :banned_phrases
3698
+
3699
+ def initialize(**args)
3700
+ update!(**args)
3701
+ end
3702
+
3703
+ # Update properties of this object
3704
+ def update!(**args)
3705
+ @banned_phrases = args[:banned_phrases] if args.key?(:banned_phrases)
3706
+ end
3707
+ end
3708
+
3709
+ # Customer policy enforcement result for the Model Armor policy.
3710
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultModelArmorEnforcementResult
3711
+ include Google::Apis::Core::Hashable
3712
+
3713
+ # The `Status` type defines a logical error model that is suitable for different
3714
+ # programming environments, including REST APIs and RPC APIs. It is used by [
3715
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
3716
+ # data: error code, error message, and error details. You can find out more
3717
+ # about this error model and how to work with it in the [API Design Guide](https:
3718
+ # //cloud.google.com/apis/design/errors).
3719
+ # Corresponds to the JSON property `error`
3720
+ # @return [Google::Apis::DiscoveryengineV1::GoogleRpcStatus]
3721
+ attr_accessor :error
3722
+
3723
+ # The Model Armor violation that was found.
3724
+ # Corresponds to the JSON property `modelArmorViolation`
3725
+ # @return [String]
3726
+ attr_accessor :model_armor_violation
3727
+
3728
+ def initialize(**args)
3729
+ update!(**args)
3730
+ end
3731
+
3732
+ # Update properties of this object
3733
+ def update!(**args)
3734
+ @error = args[:error] if args.key?(:error)
3735
+ @model_armor_violation = args[:model_armor_violation] if args.key?(:model_armor_violation)
3736
+ end
3737
+ end
3738
+
3739
+ # Customer policy enforcement result for a single policy type.
3740
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultPolicyEnforcementResult
3741
+ include Google::Apis::Core::Hashable
3742
+
3743
+ # Customer policy enforcement result for the banned phrase policy.
3744
+ # Corresponds to the JSON property `bannedPhraseEnforcementResult`
3745
+ # @return [Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultBannedPhraseEnforcementResult]
3746
+ attr_accessor :banned_phrase_enforcement_result
3747
+
3748
+ # Customer policy enforcement result for the Model Armor policy.
3749
+ # Corresponds to the JSON property `modelArmorEnforcementResult`
3750
+ # @return [Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultModelArmorEnforcementResult]
3751
+ attr_accessor :model_armor_enforcement_result
3752
+
3753
+ def initialize(**args)
3754
+ update!(**args)
3755
+ end
3756
+
3757
+ # Update properties of this object
3758
+ def update!(**args)
3759
+ @banned_phrase_enforcement_result = args[:banned_phrase_enforcement_result] if args.key?(:banned_phrase_enforcement_result)
3760
+ @model_armor_enforcement_result = args[:model_armor_enforcement_result] if args.key?(:model_armor_enforcement_result)
3761
+ end
3762
+ end
3763
+
3654
3764
  # One part of the multi-part response of the assist call.
3655
3765
  class GoogleCloudDiscoveryengineV1AssistAnswerReply
3656
3766
  include Google::Apis::Core::Hashable
@@ -3913,6 +4023,12 @@ module Google
3913
4023
  # @return [Array<Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistantCustomerPolicyBannedPhrase>]
3914
4024
  attr_accessor :banned_phrases
3915
4025
 
4026
+ # Configuration for customer defined Model Armor templates to be used for
4027
+ # sanitizing user prompts and assistant responses.
4028
+ # Corresponds to the JSON property `modelArmorConfig`
4029
+ # @return [Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistantCustomerPolicyModelArmorConfig]
4030
+ attr_accessor :model_armor_config
4031
+
3916
4032
  def initialize(**args)
3917
4033
  update!(**args)
3918
4034
  end
@@ -3920,6 +4036,7 @@ module Google
3920
4036
  # Update properties of this object
3921
4037
  def update!(**args)
3922
4038
  @banned_phrases = args[:banned_phrases] if args.key?(:banned_phrases)
4039
+ @model_armor_config = args[:model_armor_config] if args.key?(:model_armor_config)
3923
4040
  end
3924
4041
  end
3925
4042
 
@@ -3958,6 +4075,44 @@ module Google
3958
4075
  end
3959
4076
  end
3960
4077
 
4078
+ # Configuration for customer defined Model Armor templates to be used for
4079
+ # sanitizing user prompts and assistant responses.
4080
+ class GoogleCloudDiscoveryengineV1AssistantCustomerPolicyModelArmorConfig
4081
+ include Google::Apis::Core::Hashable
4082
+
4083
+ # Optional. Defines the failure mode for Model Armor sanitization.
4084
+ # Corresponds to the JSON property `failureMode`
4085
+ # @return [String]
4086
+ attr_accessor :failure_mode
4087
+
4088
+ # Optional. The resource name of the Model Armor template for sanitizing
4089
+ # assistant responses. Format: `projects/`project`/locations/`location`/
4090
+ # templates/`template_id`` If not specified, no sanitization will be applied to
4091
+ # the assistant response.
4092
+ # Corresponds to the JSON property `responseTemplate`
4093
+ # @return [String]
4094
+ attr_accessor :response_template
4095
+
4096
+ # Optional. The resource name of the Model Armor template for sanitizing user
4097
+ # prompts. Format: `projects/`project`/locations/`location`/templates/`
4098
+ # template_id`` If not specified, no sanitization will be applied to the user
4099
+ # prompt.
4100
+ # Corresponds to the JSON property `userPromptTemplate`
4101
+ # @return [String]
4102
+ attr_accessor :user_prompt_template
4103
+
4104
+ def initialize(**args)
4105
+ update!(**args)
4106
+ end
4107
+
4108
+ # Update properties of this object
4109
+ def update!(**args)
4110
+ @failure_mode = args[:failure_mode] if args.key?(:failure_mode)
4111
+ @response_template = args[:response_template] if args.key?(:response_template)
4112
+ @user_prompt_template = args[:user_prompt_template] if args.key?(:user_prompt_template)
4113
+ end
4114
+ end
4115
+
3961
4116
  # Configuration for the generation of the assistant response.
3962
4117
  class GoogleCloudDiscoveryengineV1AssistantGenerationConfig
3963
4118
  include Google::Apis::Core::Hashable
@@ -16,13 +16,13 @@ module Google
16
16
  module Apis
17
17
  module DiscoveryengineV1
18
18
  # Version of the google-apis-discoveryengine_v1 gem
19
- GEM_VERSION = "0.50.0"
19
+ GEM_VERSION = "0.51.0"
20
20
 
21
21
  # Version of the code generator used to generate this client
22
22
  GENERATOR_VERSION = "0.18.0"
23
23
 
24
24
  # Revision of the discovery document this client was generated from
25
- REVISION = "20250902"
25
+ REVISION = "20250908"
26
26
  end
27
27
  end
28
28
  end
@@ -562,6 +562,30 @@ module Google
562
562
  include Google::Apis::Core::JsonObjectSupport
563
563
  end
564
564
 
565
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResult
566
+ class Representation < Google::Apis::Core::JsonRepresentation; end
567
+
568
+ include Google::Apis::Core::JsonObjectSupport
569
+ end
570
+
571
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultBannedPhraseEnforcementResult
572
+ class Representation < Google::Apis::Core::JsonRepresentation; end
573
+
574
+ include Google::Apis::Core::JsonObjectSupport
575
+ end
576
+
577
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultModelArmorEnforcementResult
578
+ class Representation < Google::Apis::Core::JsonRepresentation; end
579
+
580
+ include Google::Apis::Core::JsonObjectSupport
581
+ end
582
+
583
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultPolicyEnforcementResult
584
+ class Representation < Google::Apis::Core::JsonRepresentation; end
585
+
586
+ include Google::Apis::Core::JsonObjectSupport
587
+ end
588
+
565
589
  class GoogleCloudDiscoveryengineV1AssistAnswerReply
566
590
  class Representation < Google::Apis::Core::JsonRepresentation; end
567
591
 
@@ -622,6 +646,12 @@ module Google
622
646
  include Google::Apis::Core::JsonObjectSupport
623
647
  end
624
648
 
649
+ class GoogleCloudDiscoveryengineV1AssistantCustomerPolicyModelArmorConfig
650
+ class Representation < Google::Apis::Core::JsonRepresentation; end
651
+
652
+ include Google::Apis::Core::JsonObjectSupport
653
+ end
654
+
625
655
  class GoogleCloudDiscoveryengineV1AssistantGenerationConfig
626
656
  class Representation < Google::Apis::Core::JsonRepresentation; end
627
657
 
@@ -5329,6 +5359,8 @@ module Google
5329
5359
  # @private
5330
5360
  class Representation < Google::Apis::Core::JsonRepresentation
5331
5361
  collection :assist_skipped_reasons, as: 'assistSkippedReasons'
5362
+ property :customer_policy_enforcement_result, as: 'customerPolicyEnforcementResult', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResult, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResult::Representation
5363
+
5332
5364
  property :name, as: 'name'
5333
5365
  collection :replies, as: 'replies', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerReply, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerReply::Representation
5334
5366
 
@@ -5336,6 +5368,41 @@ module Google
5336
5368
  end
5337
5369
  end
5338
5370
 
5371
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResult
5372
+ # @private
5373
+ class Representation < Google::Apis::Core::JsonRepresentation
5374
+ collection :policy_results, as: 'policyResults', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultPolicyEnforcementResult, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultPolicyEnforcementResult::Representation
5375
+
5376
+ property :verdict, as: 'verdict'
5377
+ end
5378
+ end
5379
+
5380
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultBannedPhraseEnforcementResult
5381
+ # @private
5382
+ class Representation < Google::Apis::Core::JsonRepresentation
5383
+ collection :banned_phrases, as: 'bannedPhrases'
5384
+ end
5385
+ end
5386
+
5387
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultModelArmorEnforcementResult
5388
+ # @private
5389
+ class Representation < Google::Apis::Core::JsonRepresentation
5390
+ property :error, as: 'error', class: Google::Apis::DiscoveryengineV1::GoogleRpcStatus, decorator: Google::Apis::DiscoveryengineV1::GoogleRpcStatus::Representation
5391
+
5392
+ property :model_armor_violation, as: 'modelArmorViolation'
5393
+ end
5394
+ end
5395
+
5396
+ class GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultPolicyEnforcementResult
5397
+ # @private
5398
+ class Representation < Google::Apis::Core::JsonRepresentation
5399
+ property :banned_phrase_enforcement_result, as: 'bannedPhraseEnforcementResult', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultBannedPhraseEnforcementResult, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultBannedPhraseEnforcementResult::Representation
5400
+
5401
+ property :model_armor_enforcement_result, as: 'modelArmorEnforcementResult', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultModelArmorEnforcementResult, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistAnswerCustomerPolicyEnforcementResultModelArmorEnforcementResult::Representation
5402
+
5403
+ end
5404
+ end
5405
+
5339
5406
  class GoogleCloudDiscoveryengineV1AssistAnswerReply
5340
5407
  # @private
5341
5408
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -5419,6 +5486,8 @@ module Google
5419
5486
  class Representation < Google::Apis::Core::JsonRepresentation
5420
5487
  collection :banned_phrases, as: 'bannedPhrases', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistantCustomerPolicyBannedPhrase, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistantCustomerPolicyBannedPhrase::Representation
5421
5488
 
5489
+ property :model_armor_config, as: 'modelArmorConfig', class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistantCustomerPolicyModelArmorConfig, decorator: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1AssistantCustomerPolicyModelArmorConfig::Representation
5490
+
5422
5491
  end
5423
5492
  end
5424
5493
 
@@ -5431,6 +5500,15 @@ module Google
5431
5500
  end
5432
5501
  end
5433
5502
 
5503
+ class GoogleCloudDiscoveryengineV1AssistantCustomerPolicyModelArmorConfig
5504
+ # @private
5505
+ class Representation < Google::Apis::Core::JsonRepresentation
5506
+ property :failure_mode, as: 'failureMode'
5507
+ property :response_template, as: 'responseTemplate'
5508
+ property :user_prompt_template, as: 'userPromptTemplate'
5509
+ end
5510
+ end
5511
+
5434
5512
  class GoogleCloudDiscoveryengineV1AssistantGenerationConfig
5435
5513
  # @private
5436
5514
  class Representation < Google::Apis::Core::JsonRepresentation
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-discoveryengine_v1
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.50.0
4
+ version: 0.51.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
@@ -57,7 +57,7 @@ licenses:
57
57
  metadata:
58
58
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
59
59
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-discoveryengine_v1/CHANGELOG.md
60
- documentation_uri: https://googleapis.dev/ruby/google-apis-discoveryengine_v1/v0.50.0
60
+ documentation_uri: https://googleapis.dev/ruby/google-apis-discoveryengine_v1/v0.51.0
61
61
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-discoveryengine_v1
62
62
  rdoc_options: []
63
63
  require_paths: