Class: Google::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate

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

Overview

A response candidate generated from the model.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate

Returns a new instance of GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidate.



5679
5680
5681
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 5679

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

Instance Attribute Details

#contentGoogle::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1GroundedGenerationContent

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



5662
5663
5664
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 5662

def content
  @content
end

#grounding_metadataGoogle::Apis::DiscoveryengineV1::GoogleCloudDiscoveryengineV1GenerateGroundedContentResponseCandidateGroundingMetadata

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



5667
5668
5669
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 5667

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)


5672
5673
5674
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 5672

def grounding_score
  @grounding_score
end

#indexFixnum

Index of the candidate. Corresponds to the JSON property index

Returns:

  • (Fixnum)


5677
5678
5679
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 5677

def index
  @index
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5684
5685
5686
5687
5688
5689
# File 'lib/google/apis/discoveryengine_v1/classes.rb', line 5684

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