View Source GoogleApi.AIPlatform.V1.Api.Publishers (google_api_ai_platform v0.24.0)
API calls for all endpoints tagged Publishers.
Summary
Functions
aiplatform_publishers_models_compute_tokens(connection, endpoint, optional_params \\ [], opts \\ [])
Return a list of tokens based on the input text.
Perform a token counting.
Generate content with multimodal inputs.
Gets a Model Garden publisher model.
Generate content with multimodal inputs with streaming support.
Functions
aiplatform_publishers_models_compute_tokens(connection, endpoint, optional_params \\ [], opts \\ [])
@spec aiplatform_publishers_models_compute_tokens( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: {:ok, GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1ComputeTokensResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
Return a list of tokens based on the input text.
Parameters
-
connection(type:GoogleApi.AIPlatform.V1.Connection.t) - Connection to server -
endpoint(type:String.t) - Required. The name of the Endpoint requested to get lists of tokens and token ids. -
optional_params(type:keyword()) - Optional parameters-
:"$.xgafv"(type:String.t) - V1 error format. -
:access_token(type:String.t) - OAuth access token. -
:alt(type:String.t) - Data format for response. -
:callback(type:String.t) - JSONP -
:fields(type:String.t) - Selector specifying which fields to include in a partial response. -
:key(type:String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token(type:String.t) - OAuth 2.0 token for the current user. -
:prettyPrint(type:boolean()) - Returns response with indentations and line breaks. -
:quotaUser(type:String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType(type:String.t) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol(type:String.t) - Upload protocol for media (e.g. "raw", "multipart"). -
:body(type:GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1ComputeTokensRequest.t) -
-
-
opts(type:keyword()) - Call options
Returns
-
{:ok, %GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1ComputeTokensResponse{}}on success -
{:error, info}on failure
@spec aiplatform_publishers_models_count_tokens( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: {:ok, GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1CountTokensResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
Perform a token counting.
Parameters
-
connection(type:GoogleApi.AIPlatform.V1.Connection.t) - Connection to server -
endpoint(type:String.t) - Required. The name of the Endpoint requested to perform token counting. Format:projects/{project}/locations/{location}/endpoints/{endpoint} -
optional_params(type:keyword()) - Optional parameters-
:"$.xgafv"(type:String.t) - V1 error format. -
:access_token(type:String.t) - OAuth access token. -
:alt(type:String.t) - Data format for response. -
:callback(type:String.t) - JSONP -
:fields(type:String.t) - Selector specifying which fields to include in a partial response. -
:key(type:String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token(type:String.t) - OAuth 2.0 token for the current user. -
:prettyPrint(type:boolean()) - Returns response with indentations and line breaks. -
:quotaUser(type:String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType(type:String.t) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol(type:String.t) - Upload protocol for media (e.g. "raw", "multipart"). -
:body(type:GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1CountTokensRequest.t) -
-
-
opts(type:keyword()) - Call options
Returns
-
{:ok, %GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1CountTokensResponse{}}on success -
{:error, info}on failure
@spec aiplatform_publishers_models_generate_content( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: {:ok, GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1GenerateContentResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
Generate content with multimodal inputs.
Parameters
-
connection(type:GoogleApi.AIPlatform.V1.Connection.t) - Connection to server -
model(type:String.t) - Required. The fully qualified name of the publisher model or tuned model endpoint to use. Publisher model format:projects/{project}/locations/{location}/publishers/*/models/*Tuned model endpoint format:projects/{project}/locations/{location}/endpoints/{endpoint} -
optional_params(type:keyword()) - Optional parameters-
:"$.xgafv"(type:String.t) - V1 error format. -
:access_token(type:String.t) - OAuth access token. -
:alt(type:String.t) - Data format for response. -
:callback(type:String.t) - JSONP -
:fields(type:String.t) - Selector specifying which fields to include in a partial response. -
:key(type:String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token(type:String.t) - OAuth 2.0 token for the current user. -
:prettyPrint(type:boolean()) - Returns response with indentations and line breaks. -
:quotaUser(type:String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType(type:String.t) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol(type:String.t) - Upload protocol for media (e.g. "raw", "multipart"). -
:body(type:GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1GenerateContentRequest.t) -
-
-
opts(type:keyword()) - Call options
Returns
-
{:ok, %GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1GenerateContentResponse{}}on success -
{:error, info}on failure
@spec aiplatform_publishers_models_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: {:ok, GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1PublisherModel.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
Gets a Model Garden publisher model.
Parameters
-
connection(type:GoogleApi.AIPlatform.V1.Connection.t) - Connection to server -
name(type:String.t) - Required. The name of the PublisherModel resource. Format:publishers/{publisher}/models/{publisher_model} -
optional_params(type:keyword()) - Optional parameters-
:"$.xgafv"(type:String.t) - V1 error format. -
:access_token(type:String.t) - OAuth access token. -
:alt(type:String.t) - Data format for response. -
:callback(type:String.t) - JSONP -
:fields(type:String.t) - Selector specifying which fields to include in a partial response. -
:key(type:String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token(type:String.t) - OAuth 2.0 token for the current user. -
:prettyPrint(type:boolean()) - Returns response with indentations and line breaks. -
:quotaUser(type:String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType(type:String.t) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol(type:String.t) - Upload protocol for media (e.g. "raw", "multipart"). -
:huggingFaceToken(type:String.t) - Optional. Token used to access Hugging Face gated models. -
:isHuggingFaceModel(type:boolean()) - Optional. Boolean indicates whether the requested model is a Hugging Face model. -
:languageCode(type:String.t) - Optional. The IETF BCP-47 language code representing the language in which the publisher model's text information should be written in. -
:view(type:String.t) - Optional. PublisherModel view specifying which fields to read.
-
-
opts(type:keyword()) - Call options
Returns
-
{:ok, %GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1PublisherModel{}}on success -
{:error, info}on failure
aiplatform_publishers_models_stream_generate_content(connection, model, optional_params \\ [], opts \\ [])
@spec aiplatform_publishers_models_stream_generate_content( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: {:ok, GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1GenerateContentResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()}
Generate content with multimodal inputs with streaming support.
Parameters
-
connection(type:GoogleApi.AIPlatform.V1.Connection.t) - Connection to server -
model(type:String.t) - Required. The fully qualified name of the publisher model or tuned model endpoint to use. Publisher model format:projects/{project}/locations/{location}/publishers/*/models/*Tuned model endpoint format:projects/{project}/locations/{location}/endpoints/{endpoint} -
optional_params(type:keyword()) - Optional parameters-
:"$.xgafv"(type:String.t) - V1 error format. -
:access_token(type:String.t) - OAuth access token. -
:alt(type:String.t) - Data format for response. -
:callback(type:String.t) - JSONP -
:fields(type:String.t) - Selector specifying which fields to include in a partial response. -
:key(type:String.t) - API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. -
:oauth_token(type:String.t) - OAuth 2.0 token for the current user. -
:prettyPrint(type:boolean()) - Returns response with indentations and line breaks. -
:quotaUser(type:String.t) - Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. -
:uploadType(type:String.t) - Legacy upload protocol for media (e.g. "media", "multipart"). -
:upload_protocol(type:String.t) - Upload protocol for media (e.g. "raw", "multipart"). -
:body(type:GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1GenerateContentRequest.t) -
-
-
opts(type:keyword()) - Call options
Returns
-
{:ok, %GoogleApi.AIPlatform.V1.Model.GoogleCloudAiplatformV1GenerateContentResponse{}}on success -
{:error, info}on failure