Model Groups

class indico.queries.model_groups.CreateModelGroup(name, dataset_id, source_column_id, labelset_id, wait=False, model_training_options=None, model_type=None)

Create a new model group and train a model

Parameters
  • name (str) – Name of the new model group

  • dataset_id (int) – id of the dataset that this model group is based upon

  • source_column_id (int) – id of the source column to use in training this model group. Usually the id of source text or images.

  • labelset_id (int) – id of the labelset (labeled data) to use in training this model group

  • wait (bool) – Wait for this model group to finish training. Default is False

  • model_type (str) – The model type to use, defaults to the default model type for the dataset type.

Returns

ModelGroup object

Raises:

class indico.queries.model_groups.ModelGroupPredict(model_id, data, load=True, predict_options=None)

Generate predictions from a model group on new data

Parameters
  • model_id= (int) – selected model id use for predictions

  • data= (List[str]) – list of samples to predict

  • predict_options= (JSONString) – arguments for predictions

Returns

Job associated with this model group predict task

Raises:

class indico.queries.model_groups.GetModelGroup(id)

Get an object describing a model group

Parameters

id (int) – model group id to query

Returns

ModelGroup object

Raises:

class indico.queries.model_groups.GetModelGroupSelectedModelStatus(id)

Get the status string of the selected model for the given model group id

Parameters

id (int) – model group id to query

Returns

CREATED, TRAINING, COMPLETE or FAILED

Return type

status (str)

Raises: