DeepchecksClient.get_or_create_model#

DeepchecksClient.get_or_create_model(name: str, task_type: Optional[Union[str, TaskType]] = None, description: Optional[str] = None, create_model_defaults: bool = True, alerts_delay_labels_ratio: float = 1.0, alerts_delay_seconds: int = 259200, model_notes: Optional[List[Dict[str, str]]] = None, monitoring_frequency: str = 'day', obj_store_path: Optional[str] = None) DeepchecksModelClient#

Retrieve a model client based on its name if exists, or creates a new model with the provided parameters.

A model client is a client to interact with a specific model. It is used to update checks, monitors and alerts associated with the model. In addition, it can be used to create a new model version.

Parameters
name: str

Display name of the model.

task_type: str, default: None

Task type of the model, possible values are regression, multiclass, binary. Required for creation of a new model.

description: str, default: None

Additional description for the model.

create_model_defaults: bool, default: True

Whether to add default check, monitors and alerts to the model.

alerts_delay_labels_ratio: float, default: 1.0

For alerts which needs labels, set the minimum ratio required to trigger the alert calculation, together with alerts_delay_seconds, trigger occurs on the earliest of the two.

alerts_delay_seconds: int, default: 3 days

For alerts which needs labels, set the minimum time since the data was sent, in order to trigger the alert calculation. Together with alerts_delay_labels_ratio, trigger occurs on the earliest of the two.

model_notes: Optional[List[Dict[str, str]]] , default None

list of model notes. Each dictionary expected to contain only two keys ‘title’ and ‘text’.

monitoring_frequencystr, default ‘day’

The frequency & aggregation window for the default monitors and alerts. One of ‘hour’, ‘day’, ‘week’, ‘month’.

obj_store_pathstr, default None

The path to the model data in the object store. The authentication info should be provided inside the system.

Returns
DeepchecksModelClient

Client to interact with the model.