Skip to content

Release Checkpoint

Release a checkpoint, making it available for creating new indexes in Marqo Cloud.


POST /models/{model_id}/released-checkpoints/{checkpoint_id}

Example: Releasing a checkpoint

from marqtune.client import Client
from marqtune.enums import ModelType, DatasetType, InstanceType

url = "https://marqtune.marqo.ai"
api_key = "{api_key}"
model_id = "{model_id}"
marqtune_client = Client(url=url, api_key=api_key)
model = marqtune_client.model(model_id)
model.release('epoch_4')
# Train a model.
cURL -X POST 'https://marqtune.marqo.ai/models/{model_id}/released-checkpoints/{checkpoint_id}' \
     --header 'x-api-key: {api_key}'

Response: 202 Accepted

Training task has been initalised and will now be executed.

{
    "statusCode": 202,
    "body": {
        "modelId": "model_id"
    }
}

Response: 400 (Invalid dataset)

Invalid dataset

{
    "statusCode": 400,
    "body": {
      "message": "Dataset must be of type 'training'"
    }
}

Response: 400 (Invalid base model)

Invalid base model

{
    "statusCode": 400,
    "body": {
      "message": "Model with id {base_model} not found"
    }
}

Response: 400 (Invalid checkpoint)

Invalid checkpoint

{
    "statusCode": 400,
    "body": {
      "message": "Invalid checkpoint. Available checkpoints: {checkpoints}"
    }
}

Response: 400 (Invalid hyperparameters)

Invalid hyperparameters are present in the data schema of the dataset

{
    "statusCode": 400,
    "body": {
      "message": "Invalid <left|right> key: <hyperparameter key> not found in the data schema"
    }
}

Response: 400 (Invalid hyperparameters)

Invalid weight key is present in the data schema of the dataset

{
    "statusCode": 400,
    "body": {
      "message": "Invalid weight key: <weight_key> not found in the data schema"
    }
}

Response: 400 (Invalid Request)

Request path or method is invalid.

{
    "statusCode": 400,
    "body": {
      "message": "Invalid request method"
    }
}

Response: 401 (Unauthorised)

Unauthorised. Check your API key and try again.

{
  "message": "Unauthorized."
}

Response: 500 (Internal server error)

Internal server error. Check your API key and try again.

{
  "message": "Internal server error."
}