Class: Google::Cloud::AIPlatform::V1::CachedContent

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/aiplatform/v1/cached_content.rb

Overview

A resource used in LLM queries for users to explicitly specify what to cache and how to cache.

Defined Under Namespace

Classes: UsageMetadata

Instance Attribute Summary collapse

Instance Attribute Details

#contents::Array<::Google::Cloud::AIPlatform::V1::Content>

Returns Optional. Input only. Immutable. The content to cache.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#create_time::Google::Protobuf::Timestamp (readonly)

Returns Output only. Creation time of the cache entry.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#display_name::String

Returns Optional. Immutable. The user-generated meaningful display name of the cached content.

Returns:

  • (::String)

    Optional. Immutable. The user-generated meaningful display name of the cached content.



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#encryption_spec::Google::Cloud::AIPlatform::V1::EncryptionSpec

Returns Input only. Immutable. Customer-managed encryption key spec for a CachedContent. If set, this CachedContent and all its sub-resources will be secured by this key.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#expire_time::Google::Protobuf::Timestamp

Returns Timestamp of when this resource is considered expired. This is always provided on output, regardless of what was sent on input.

Note: The following fields are mutually exclusive: expire_time, ttl. If a field in that set is populated, all other fields in the set will automatically be cleared.

Returns:

  • (::Google::Protobuf::Timestamp)

    Timestamp of when this resource is considered expired. This is always provided on output, regardless of what was sent on input.

    Note: The following fields are mutually exclusive: expire_time, ttl. If a field in that set is populated, all other fields in the set will automatically be cleared.



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#model::String

Returns Immutable. The name of the Model to use for cached content. Currently, only the published Gemini base models are supported, in form of projects/{PROJECT}/locations/{LOCATION}/publishers/google/models/{MODEL}.

Returns:

  • (::String)

    Immutable. The name of the Model to use for cached content. Currently, only the published Gemini base models are supported, in form of projects/{PROJECT}/locations/{LOCATION}/publishers/google/models/{MODEL}



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#name::String

Returns Immutable. Identifier. The server-generated resource name of the cached content Format: projects/{project}/locations/{location}/cachedContents/{cached_content}.

Returns:

  • (::String)

    Immutable. Identifier. The server-generated resource name of the cached content Format: projects/{project}/locations/{location}/cachedContents/{cached_content}



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#system_instruction::Google::Cloud::AIPlatform::V1::Content

Returns Optional. Input only. Immutable. Developer set system instruction. Currently, text only.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#tool_config::Google::Cloud::AIPlatform::V1::ToolConfig

Returns Optional. Input only. Immutable. Tool config. This config is shared for all tools.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#tools::Array<::Google::Cloud::AIPlatform::V1::Tool>

Returns Optional. Input only. Immutable. A list of Tools the model may use to generate the next response.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#ttl::Google::Protobuf::Duration

Returns Input only. The TTL for this resource. The expiration time is computed: now + TTL.

Note: The following fields are mutually exclusive: ttl, expire_time. If a field in that set is populated, all other fields in the set will automatically be cleared.

Returns:

  • (::Google::Protobuf::Duration)

    Input only. The TTL for this resource. The expiration time is computed: now + TTL.

    Note: The following fields are mutually exclusive: ttl, expire_time. If a field in that set is populated, all other fields in the set will automatically be cleared.



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#update_time::Google::Protobuf::Timestamp (readonly)

Returns Output only. When the cache entry was last updated in UTC time.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#usage_metadata::Google::Cloud::AIPlatform::V1::CachedContent::UsageMetadata (readonly)

Returns Output only. Metadata on the usage of the cached content.

Returns:



82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
# File 'proto_docs/google/cloud/aiplatform/v1/cached_content.rb', line 82

class CachedContent
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Metadata on the usage of the cached content.
  # @!attribute [rw] total_token_count
  #   @return [::Integer]
  #     Total number of tokens that the cached content consumes.
  # @!attribute [rw] text_count
  #   @return [::Integer]
  #     Number of text characters.
  # @!attribute [rw] image_count
  #   @return [::Integer]
  #     Number of images.
  # @!attribute [rw] video_duration_seconds
  #   @return [::Integer]
  #     Duration of video in seconds.
  # @!attribute [rw] audio_duration_seconds
  #   @return [::Integer]
  #     Duration of audio in seconds.
  class 
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end