Class: Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate

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

A response candidate generated from the model.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate

Returns a new instance of GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidate.



10694
10695
10696
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 10694

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

Instance Attribute Details

#contentGoogle::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaGroundedGenerationContent

Base structured datatype containing multi-part content of a message. Corresponds to the JSON property content



10677
10678
10679
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 10677

def content
  @content
end

#grounding_metadataGoogle::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaGenerateGroundedContentResponseCandidateGroundingMetadata

Citation for the generated content. Corresponds to the JSON property groundingMetadata



10682
10683
10684
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 10682

def 
  @grounding_metadata
end

#grounding_scoreFloat

The overall grounding score for the candidate, in the range of [0, 1]. Corresponds to the JSON property groundingScore

Returns:

  • (Float)


10687
10688
10689
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 10687

def grounding_score
  @grounding_score
end

#indexFixnum

Index of the candidate. Corresponds to the JSON property index

Returns:

  • (Fixnum)


10692
10693
10694
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 10692

def index
  @index
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



10699
10700
10701
10702
10703
10704
# File 'lib/google/apis/discoveryengine_v1alpha/classes.rb', line 10699

def update!(**args)
  @content = args[:content] if args.key?(:content)
  @grounding_metadata = args[:grounding_metadata] if args.key?(:grounding_metadata)
  @grounding_score = args[:grounding_score] if args.key?(:grounding_score)
  @index = args[:index] if args.key?(:index)
end