Class: Google::Apis::AiplatformV1::CloudAiNlLlmProtoServiceCandidate

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ CloudAiNlLlmProtoServiceCandidate

Returns a new instance of CloudAiNlLlmProtoServiceCandidate.



476
477
478
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 476

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

Instance Attribute Details

#citation_metadataGoogle::Apis::AiplatformV1::CloudAiNlLlmProtoServiceCitationMetadata

A collection of source attributions for a piece of content. Corresponds to the JSON property citationMetadata



448
449
450
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 448

def 
  @citation_metadata
end

#contentGoogle::Apis::AiplatformV1::CloudAiNlLlmProtoServiceContent

The content of a single message from a participant. Corresponds to the JSON property content



453
454
455
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 453

def content
  @content
end

#finish_messageString

A string that describes the filtering behavior in more detail. Only filled when reason is set. Corresponds to the JSON property finishMessage

Returns:

  • (String)


459
460
461
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 459

def finish_message
  @finish_message
end

#finish_reasonString

The reason why the model stopped generating tokens. Corresponds to the JSON property finishReason

Returns:

  • (String)


464
465
466
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 464

def finish_reason
  @finish_reason
end

#indexFixnum

Index of the candidate. Corresponds to the JSON property index

Returns:

  • (Fixnum)


469
470
471
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 469

def index
  @index
end

#safety_ratingsArray<Google::Apis::AiplatformV1::CloudAiNlLlmProtoServiceSafetyRating>

Safety ratings of the generated content. Corresponds to the JSON property safetyRatings



474
475
476
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 474

def safety_ratings
  @safety_ratings
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



481
482
483
484
485
486
487
488
# File 'lib/google/apis/aiplatform_v1/classes.rb', line 481

def update!(**args)
  @citation_metadata = args[:citation_metadata] if args.key?(:citation_metadata)
  @content = args[:content] if args.key?(:content)
  @finish_message = args[:finish_message] if args.key?(:finish_message)
  @finish_reason = args[:finish_reason] if args.key?(:finish_reason)
  @index = args[:index] if args.key?(:index)
  @safety_ratings = args[:safety_ratings] if args.key?(:safety_ratings)
end