MLflow models
Finalize Logged Model
PATCH
/
api
/
2.0
/
mlflow
/
logged-models
/
{model_id}
Finalize Logged Model
curl --request PATCH \
--url https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id} \
--header 'Content-Type: application/json' \
--data '
{
"model_id": "logged_model_12345"
}
'import requests
url = "https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}"
payload = { "model_id": "logged_model_12345" }
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({model_id: 'logged_model_12345'})
};
fetch('https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'model_id' => 'logged_model_12345'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}"
payload := strings.NewReader("{\n \"model_id\": \"logged_model_12345\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}")
.header("Content-Type", "application/json")
.body("{\n \"model_id\": \"logged_model_12345\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"model_id\": \"logged_model_12345\"\n}"
response = http.request(request)
puts response.read_body{
"model": {
"info": {
"model_id": "logged_model_12345",
"experiment_id": "exp_001",
"name": "my_awesome_model",
"creation_timestamp_ms": 1678886400000,
"last_updated_timestamp_ms": 1678887000000,
"artifact_uri": "s3://my-bucket/models/my_awesome_model",
"status": "LOGGED_MODEL_STATUS_UNSPECIFIED",
"creator_id": 12345,
"model_type": "Classifier",
"source_run_id": "run_abcd1234efgh5678",
"status_message": "Model successfully logged.",
"tags": [
{
"key": "<string>",
"value": "<string>"
}
],
"registrations": [
{
"name": "<string>",
"version": "<string>"
}
]
},
"data": {
"params": [
{
"key": "<string>",
"value": "<string>"
}
],
"metrics": [
{
"key": "<string>",
"step": "0",
"timestamp": 123,
"value": 123
}
]
}
}
}Path Parameters
The unique identifier for the logged model to finalize.
Body
application/json
Request body for finalizing a logged model.
The ID of the LoggedModel to finalize.
Example:
"logged_model_12345"
Whether or not the model is ready for use. Valid values in this message: LOGGED_MODEL_READY, LOGGED_MODEL_UPLOAD_FAILED ("LOGGED_MODEL_UPLOAD_FAILED" indicates that something went wrong when logging the model weights / agent code)
Available options:
LOGGED_MODEL_STATUS_UNSPECIFIED, LOGGED_MODEL_PENDING, LOGGED_MODEL_READY, LOGGED_MODEL_UPLOAD_FAILED Response
200 - application/json
Successful response
Response body for finalizing a logged model.
A LoggedModel message includes logged model attributes, tags, registration info, params, and linked run metrics.
Show child attributes
Show child attributes
Was this page helpful?
⌘I
Finalize Logged Model
curl --request PATCH \
--url https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id} \
--header 'Content-Type: application/json' \
--data '
{
"model_id": "logged_model_12345"
}
'import requests
url = "https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}"
payload = { "model_id": "logged_model_12345" }
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({model_id: 'logged_model_12345'})
};
fetch('https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'model_id' => 'logged_model_12345'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}"
payload := strings.NewReader("{\n \"model_id\": \"logged_model_12345\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}")
.header("Content-Type", "application/json")
.body("{\n \"model_id\": \"logged_model_12345\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mycluster.domino.tech/api/2.0/mlflow/logged-models/{model_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"model_id\": \"logged_model_12345\"\n}"
response = http.request(request)
puts response.read_body{
"model": {
"info": {
"model_id": "logged_model_12345",
"experiment_id": "exp_001",
"name": "my_awesome_model",
"creation_timestamp_ms": 1678886400000,
"last_updated_timestamp_ms": 1678887000000,
"artifact_uri": "s3://my-bucket/models/my_awesome_model",
"status": "LOGGED_MODEL_STATUS_UNSPECIFIED",
"creator_id": 12345,
"model_type": "Classifier",
"source_run_id": "run_abcd1234efgh5678",
"status_message": "Model successfully logged.",
"tags": [
{
"key": "<string>",
"value": "<string>"
}
],
"registrations": [
{
"name": "<string>",
"version": "<string>"
}
]
},
"data": {
"params": [
{
"key": "<string>",
"value": "<string>"
}
],
"metrics": [
{
"key": "<string>",
"step": "0",
"timestamp": 123,
"value": 123
}
]
}
}
}