Class: Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1EmbedContentResponse

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

Overview

Response message for PredictionService.EmbedContent.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudAiplatformV1beta1EmbedContentResponse

Returns a new instance of GoogleCloudAiplatformV1beta1EmbedContentResponse.



9577
9578
9579
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 9577

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

Instance Attribute Details

#embeddingGoogle::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1EmbedContentResponseEmbedding

A list of floats representing an embedding. Corresponds to the JSON property embedding



9563
9564
9565
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 9563

def embedding
  @embedding
end

#truncatedBoolean Also known as: truncated?

Whether the input content was truncated before generating the embedding. Corresponds to the JSON property truncated

Returns:

  • (Boolean)


9568
9569
9570
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 9568

def truncated
  @truncated
end

#usage_metadataGoogle::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1UsageMetadata

Usage metadata about the content generation request and response. This message provides a detailed breakdown of token usage and other relevant metrics. Corresponds to the JSON property usageMetadata



9575
9576
9577
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 9575

def 
  @usage_metadata
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



9582
9583
9584
9585
9586
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 9582

def update!(**args)
  @embedding = args[:embedding] if args.key?(:embedding)
  @truncated = args[:truncated] if args.key?(:truncated)
  @usage_metadata = args[:usage_metadata] if args.key?(:usage_metadata)
end