Skip to main content
The Model Shards API allows you to create, list, and delete model shards. A model shard represents a shard of a model for a DataProvider.

Resource

ModelShard

name
string
required
Resource name with pattern dataProviders/{data_provider}/modelShards/{model_shard}
model_release
string
required
Resource name of the ModelRelease that this is a shard of.Format: modelProviders/{model_provider}/modelSuites/{model_suite}/modelReleases/{model_release}This field is immutable after creation.
model_blob
ModelBlob
required
The blob for this model shard. This field is immutable after creation.
model_blob.model_blob_path
string
required
The path the model blob can be downloaded from.This field is immutable after creation.
create_time
Timestamp
When the ModelShard was created

Methods

CreateModelShard

Creates a new ModelShard.
parent
string
required
Resource name of the parent DataProvider.Format: dataProviders/{data_provider}
model_shard
ModelShard
required
The ModelShard to create. The name field will be ignored, and the system will assign an ID.Required fields:
  • model_release: Reference to a ModelRelease
  • model_blob: The model blob reference
  • model_blob.model_blob_path: Path to the model blob
Response Returns the created ModelShard resource. Example Request
CreateModelShardRequest {
  parent: "dataProviders/123"
  model_shard: {
    model_release: "modelProviders/456/modelSuites/789/modelReleases/101"
    model_blob: {
      model_blob_path: "gs://bucket/path/to/model.pb"
    }
  }
}

ListModelShards

Lists ModelShard resources for a DataProvider.
parent
string
required
Resource name of the parent DataProvider.Format: dataProviders/{data_provider}
page_size
int32
The maximum number of ModelShards to return. The service may return fewer than this value.
  • If unspecified, at most 50 ModelShards will be returned
  • Maximum value is 1000; values above 1000 will be coerced to 1000
page_token
string
A page token received from a previous ListModelShards call. Provide this to retrieve the subsequent page.When paginating, all other parameters must match the call that provided the page token.
Response
model_shards
ModelShard[]
List of ModelShard resources
next_page_token
string
A token that can be sent as page_token to retrieve the next page. If omitted, there are no subsequent pages.
Example Request
ListModelShardsRequest {
  parent: "dataProviders/123"
  page_size: 50
}

DeleteModelShard

Deletes an existing ModelShard.
name
string
required
The name of the ModelShard to delete.Format: dataProviders/{data_provider}/modelShards/{model_shard}
Response Returns an empty response on success. Example Request
DeleteModelShardRequest {
  name: "dataProviders/123/modelShards/456"
}

Build docs developers (and LLMs) love