All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.databricks.sdk.service.serving.ServedEntityOutput Maven / Gradle / Ivy

There is a newer version: 0.38.0
Show newest version
// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT.

package com.databricks.sdk.service.serving;

import com.databricks.sdk.support.Generated;
import com.databricks.sdk.support.ToStringer;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Map;
import java.util.Objects;

@Generated
public class ServedEntityOutput {
  /** The creation timestamp of the served entity in Unix time. */
  @JsonProperty("creation_timestamp")
  private Long creationTimestamp;

  /** The email of the user who created the served entity. */
  @JsonProperty("creator")
  private String creator;

  /**
   * The name of the entity served. The entity may be a model in the Databricks Model Registry, a
   * model in the Unity Catalog (UC), or a function of type FEATURE_SPEC in the UC. If it is a UC
   * object, the full name of the object is given in the form of
   * __catalog_name__.__schema_name__.__model_name__.
   */
  @JsonProperty("entity_name")
  private String entityName;

  /**
   * The version of the served entity in Databricks Model Registry or empty if the entity is a
   * FEATURE_SPEC.
   */
  @JsonProperty("entity_version")
  private String entityVersion;

  /**
   * An object containing a set of optional, user-specified environment variable key-value pairs
   * used for serving this entity. Note: this is an experimental feature and subject to change.
   * Example entity environment variables that refer to Databricks secrets: `{"OPENAI_API_KEY":
   * "{{secrets/my_scope/my_key}}", "DATABRICKS_TOKEN": "{{secrets/my_scope2/my_key2}}"}`
   */
  @JsonProperty("environment_vars")
  private Map environmentVars;

  /**
   * The external model that is served. NOTE: Only one of external_model, foundation_model, and
   * (entity_name, entity_version, workload_size, workload_type, and scale_to_zero_enabled) is
   * returned based on the endpoint type.
   */
  @JsonProperty("external_model")
  private ExternalModel externalModel;

  /**
   * The foundation model that is served. NOTE: Only one of foundation_model, external_model, and
   * (entity_name, entity_version, workload_size, workload_type, and scale_to_zero_enabled) is
   * returned based on the endpoint type.
   */
  @JsonProperty("foundation_model")
  private FoundationModel foundationModel;

  /** ARN of the instance profile that the served entity uses to access AWS resources. */
  @JsonProperty("instance_profile_arn")
  private String instanceProfileArn;

  /** The name of the served entity. */
  @JsonProperty("name")
  private String name;

  /** Whether the compute resources for the served entity should scale down to zero. */
  @JsonProperty("scale_to_zero_enabled")
  private Boolean scaleToZeroEnabled;

  /** Information corresponding to the state of the served entity. */
  @JsonProperty("state")
  private ServedModelState state;

  /**
   * The workload size of the served entity. The workload size corresponds to a range of provisioned
   * concurrency that the compute autoscales between. A single unit of provisioned concurrency can
   * process one request at a time. Valid workload sizes are "Small" (4 - 4 provisioned
   * concurrency), "Medium" (8 - 16 provisioned concurrency), and "Large" (16 - 64 provisioned
   * concurrency). If scale-to-zero is enabled, the lower bound of the provisioned concurrency for
   * each workload size will be 0.
   */
  @JsonProperty("workload_size")
  private String workloadSize;

  /**
   * The workload type of the served entity. The workload type selects which type of compute to use
   * in the endpoint. The default value for this parameter is "CPU". For deep learning workloads,
   * GPU acceleration is available by selecting workload types like GPU_SMALL and others. See the
   * available [GPU types].
   *
   * 

[GPU types]: * https://docs.databricks.com/machine-learning/model-serving/create-manage-serving-endpoints.html#gpu-workload-types */ @JsonProperty("workload_type") private String workloadType; public ServedEntityOutput setCreationTimestamp(Long creationTimestamp) { this.creationTimestamp = creationTimestamp; return this; } public Long getCreationTimestamp() { return creationTimestamp; } public ServedEntityOutput setCreator(String creator) { this.creator = creator; return this; } public String getCreator() { return creator; } public ServedEntityOutput setEntityName(String entityName) { this.entityName = entityName; return this; } public String getEntityName() { return entityName; } public ServedEntityOutput setEntityVersion(String entityVersion) { this.entityVersion = entityVersion; return this; } public String getEntityVersion() { return entityVersion; } public ServedEntityOutput setEnvironmentVars(Map environmentVars) { this.environmentVars = environmentVars; return this; } public Map getEnvironmentVars() { return environmentVars; } public ServedEntityOutput setExternalModel(ExternalModel externalModel) { this.externalModel = externalModel; return this; } public ExternalModel getExternalModel() { return externalModel; } public ServedEntityOutput setFoundationModel(FoundationModel foundationModel) { this.foundationModel = foundationModel; return this; } public FoundationModel getFoundationModel() { return foundationModel; } public ServedEntityOutput setInstanceProfileArn(String instanceProfileArn) { this.instanceProfileArn = instanceProfileArn; return this; } public String getInstanceProfileArn() { return instanceProfileArn; } public ServedEntityOutput setName(String name) { this.name = name; return this; } public String getName() { return name; } public ServedEntityOutput setScaleToZeroEnabled(Boolean scaleToZeroEnabled) { this.scaleToZeroEnabled = scaleToZeroEnabled; return this; } public Boolean getScaleToZeroEnabled() { return scaleToZeroEnabled; } public ServedEntityOutput setState(ServedModelState state) { this.state = state; return this; } public ServedModelState getState() { return state; } public ServedEntityOutput setWorkloadSize(String workloadSize) { this.workloadSize = workloadSize; return this; } public String getWorkloadSize() { return workloadSize; } public ServedEntityOutput setWorkloadType(String workloadType) { this.workloadType = workloadType; return this; } public String getWorkloadType() { return workloadType; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; ServedEntityOutput that = (ServedEntityOutput) o; return Objects.equals(creationTimestamp, that.creationTimestamp) && Objects.equals(creator, that.creator) && Objects.equals(entityName, that.entityName) && Objects.equals(entityVersion, that.entityVersion) && Objects.equals(environmentVars, that.environmentVars) && Objects.equals(externalModel, that.externalModel) && Objects.equals(foundationModel, that.foundationModel) && Objects.equals(instanceProfileArn, that.instanceProfileArn) && Objects.equals(name, that.name) && Objects.equals(scaleToZeroEnabled, that.scaleToZeroEnabled) && Objects.equals(state, that.state) && Objects.equals(workloadSize, that.workloadSize) && Objects.equals(workloadType, that.workloadType); } @Override public int hashCode() { return Objects.hash( creationTimestamp, creator, entityName, entityVersion, environmentVars, externalModel, foundationModel, instanceProfileArn, name, scaleToZeroEnabled, state, workloadSize, workloadType); } @Override public String toString() { return new ToStringer(ServedEntityOutput.class) .add("creationTimestamp", creationTimestamp) .add("creator", creator) .add("entityName", entityName) .add("entityVersion", entityVersion) .add("environmentVars", environmentVars) .add("externalModel", externalModel) .add("foundationModel", foundationModel) .add("instanceProfileArn", instanceProfileArn) .add("name", name) .add("scaleToZeroEnabled", scaleToZeroEnabled) .add("state", state) .add("workloadSize", workloadSize) .add("workloadType", workloadType) .toString(); } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy