Class: Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaCheckGroundingResponse

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/discoveryengine_v1alpha/classes.rb,
lib/google/apis/discoveryengine_v1alpha/representations.rb,
lib/google/apis/discoveryengine_v1alpha/representations.rb

Overview

Response message for the GroundedGenerationService.CheckGrounding method.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1alphaCheckGroundingResponse

Returns a new instance of GoogleCloudDiscoveryengineV1alphaCheckGroundingResponse.



6146
6147
6148
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 6146

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#cited_chunksArray<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaFactChunk>

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request. Corresponds to the JSON property citedChunks



6126
6127
6128
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 6126

def cited_chunks
  @cited_chunks
end

#cited_factsArray<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaCheckGroundingResponseCheckGroundingFactChunk>

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request. Corresponds to the JSON property citedFacts



6132
6133
6134
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 6132

def cited_facts
  @cited_facts
end

#claimsArray<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaCheckGroundingResponseClaim>

Claim texts and citation info across all claims in the answer candidate. Corresponds to the JSON property claims



6137
6138
6139
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 6137

def claims
  @claims
end

#support_scoreFloat

The support score for the input answer candidate. Higher the score, higher is the fraction of claims that are supported by the provided facts. This is always set when a response is returned. Corresponds to the JSON property supportScore

Returns:

  • (Float)


6144
6145
6146
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 6144

def support_score
  @support_score
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



6151
6152
6153
6154
6155
6156
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 6151

def update!(**args)
  @cited_chunks = args[:cited_chunks] if args.key?(:cited_chunks)
  @cited_facts = args[:cited_facts] if args.key?(:cited_facts)
  @claims = args[:claims] if args.key?(:claims)
  @support_score = args[:support_score] if args.key?(:support_score)
end