OnDemandServingMode

class oci.generative_ai_inference.models.OnDemandServingMode(**kwargs)

Bases: ServingMode

The model’s serving mode is on-demand serving on a shared infrastructure.

Attributes:

SERVING_TYPE_DEDICATED

A constant which can be used with the serving_type property of a ServingMode.

SERVING_TYPE_ON_DEMAND

A constant which can be used with the serving_type property of a ServingMode.

model_id

[Required] Gets the model_id of this OnDemandServingMode.

serving_type

[Required] Gets the serving_type of this ServingMode.

Methods:

__init__(**kwargs)

Initializes a new OnDemandServingMode object with values from keyword arguments.

get_subtype(object_dictionary)

Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.

SERVING_TYPE_DEDICATED = 'DEDICATED'

A constant which can be used with the serving_type property of a ServingMode. This constant has a value of “DEDICATED”

SERVING_TYPE_ON_DEMAND = 'ON_DEMAND'

A constant which can be used with the serving_type property of a ServingMode. This constant has a value of “ON_DEMAND”

__init__(**kwargs)

Initializes a new OnDemandServingMode object with values from keyword arguments. The default value of the serving_type attribute of this class is ON_DEMAND and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class):

Parameters
  • serving_type (str) – The value to assign to the serving_type property of this OnDemandServingMode. Allowed values for this property are: “ON_DEMAND”, “DEDICATED”

  • model_id (str) – The value to assign to the model_id property of this OnDemandServingMode.

static get_subtype(object_dictionary)

Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.

property model_id

[Required] Gets the model_id of this OnDemandServingMode. The unique ID of a model to use. You can use the list_models() API to list the available models.

Returns

The model_id of this OnDemandServingMode.

Return type

str

property serving_type

[Required] Gets the serving_type of this ServingMode. The serving mode type, which is either on-demand serving or dedicated serving.

Allowed values for this property are: “ON_DEMAND”, “DEDICATED”

Returns

The serving_type of this ServingMode.

Return type

str