Interface CreateCachedContentConfig

Optional configuration for cached content creation.

interface CreateCachedContentConfig {
    abortSignal?: AbortSignal;
    contents?: ContentListUnion;
    displayName?: string;
    expireTime?: string;
    httpOptions?: HttpOptions;
    kmsKeyName?: string;
    systemInstruction?: ContentUnion;
    toolConfig?: ToolConfig;
    tools?: Tool[];
    ttl?: string;
}

Properties

abortSignal?: AbortSignal

Abort signal which can be used to cancel the request.

NOTE: AbortSignal is a client-only operation. Using it to cancel an operation will not cancel the request in the service. You will still be charged usage for any applicable operations.

contents?: ContentListUnion

The content to cache.

displayName?: string

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

expireTime?: string

Timestamp of when this resource is considered expired. Uses RFC 3339 format, Example: 2014-10-02T15:01:23Z.

httpOptions?: HttpOptions

Used to override HTTP request options.

kmsKeyName?: string

The Cloud KMS resource identifier of the customer managed encryption key used to protect a resource. The key needs to be in the same region as where the compute resource is created. See https://cloud.google.com/vertex-ai/docs/general/cmek for more details. If this is set, then all created CachedContent objects will be encrypted with the provided encryption key. Allowed formats: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}

systemInstruction?: ContentUnion

Developer set system instruction.

toolConfig?: ToolConfig

Configuration for the tools to use. This config is shared for all tools.

tools?: Tool[]

A list of Tools the model may use to generate the next response.

ttl?: string

The TTL for this resource. The expiration time is computed: now + TTL. It is a duration string, with up to nine fractional digits, terminated by 's'. Example: "3.5s".