Compartir a través de


Fine Tuning - Get Checkpoints

Gets the checkpoints for the fine-tune job specified by the given fine-tune-id. Checkpoints are created at the end of successful epochs during training.

GET {endpoint}/openai/fine_tuning/jobs/{fine-tuning-job-id}/checkpoints?api-version=2024-06-01
GET {endpoint}/openai/fine_tuning/jobs/{fine-tuning-job-id}/checkpoints?after={after}&limit={limit}&api-version=2024-06-01

URI Parameters

Name In Required Type Description
endpoint
path True

string

url

Supported Cognitive Services endpoints (protocol and hostname, for example: https://aoairesource.openai.azure.com. Replace "aoairesource" with your Azure OpenAI account name).

fine-tuning-job-id
path True

string

The identifier of the fine-tune job.

api-version
query True

string

The requested API version.

after
query

string

Identifier for the last checkpoint ID from the previous pagination request.

limit
query

integer

int32

Number of checkpoints to retrieve. Defaults to 10.

Request Header

Name Required Type Description
api-key True

string

Provide your Cognitive Services Azure OpenAI account key here.

Responses

Name Type Description
200 OK

FineTuningJobCheckpointList

Success

Other Status Codes

ErrorResponse

An error occurred.

Security

api-key

Provide your Cognitive Services Azure OpenAI account key here.

Type: apiKey
In: header

Examples

Getting checkpoints of a fine tuning job.

Sample request

GET https://aoairesource.openai.azure.com/openai/fine_tuning/jobs/ftjob-72a2792ef7d24ba7b82c7fe4a37e379f/checkpoints?api-version=2024-06-01

Sample response

{
  "has_more": false,
  "data": [
    {
      "id": "ftckpt_qtZ5Gyk4BLq1SfLFWp3RtO3P",
      "created_at": 1646126127,
      "fine_tuned_model_checkpoint": "gpt-35-turbo-0613.ft-72a2792ef7d24ba7b82c7fe4a37e379f:ckpt-step-10",
      "step_number": 10,
      "metrics": {
        "step": 10,
        "train_loss": 0.478,
        "train_mean_token_accuracy": 0.924,
        "valid_loss": 10.112,
        "valid_mean_token_accuracy": 0.145,
        "full_valid_loss": 0.567,
        "full_valid_mean_token_accuracy": 0.944
      },
      "fine_tuning_job_id": "ftjob-72a2792ef7d24ba7b82c7fe4a37e379f",
      "object": "fine_tuning.job.checkpoint"
    },
    {
      "id": "ftckpt_frtXDR2453C4FG67t03MLPs5",
      "created_at": 1646126137,
      "fine_tuned_model_checkpoint": "gpt-35-turbo-0613.ft-72a2792ef7d24ba7b82c7fe4a37e379f:ckpt-step-20",
      "step_number": 20,
      "metrics": {
        "step": 20,
        "train_loss": 0.355,
        "train_mean_token_accuracy": 0.947,
        "valid_loss": 11.32,
        "valid_mean_token_accuracy": 0.122,
        "full_valid_loss": 0.317,
        "full_valid_mean_token_accuracy": 0.955
      },
      "fine_tuning_job_id": "ftjob-72a2792ef7d24ba7b82c7fe4a37e379f",
      "object": "fine_tuning.job.checkpoint"
    },
    {
      "id": "ftckpt_agLk6Gio560ORp14gl123fgd",
      "created_at": 1646126147,
      "fine_tuned_model_checkpoint": "gpt-35-turbo-0613.ft-72a2792ef7d24ba7b82c7fe4a37e379f:ckpt-step-30",
      "step_number": 30,
      "metrics": {
        "step": 30,
        "train_loss": 0.155,
        "train_mean_token_accuracy": 0.975,
        "valid_loss": 9.31,
        "valid_mean_token_accuracy": 0.092,
        "full_valid_loss": 0.114,
        "full_valid_mean_token_accuracy": 0.963
      },
      "fine_tuning_job_id": "ftjob-72a2792ef7d24ba7b82c7fe4a37e379f",
      "object": "fine_tuning.job.checkpoint"
    }
  ],
  "object": "list"
}

Definitions

Name Description
Error

Error

ErrorCode

ErrorCode

ErrorResponse

ErrorResponse

FineTuningJobCheckpoint

FineTuningJobCheckpoint

FineTuningJobCheckpointList

FineTuningJobCheckpointList

InnerError

InnerError

InnerErrorCode

InnerErrorCode

TypeDiscriminator

TypeDiscriminator

Error

Error

Name Type Description
code

ErrorCode

ErrorCode
Error codes as defined in the Microsoft REST guidelines (https://github.com/microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses).

details

Error[]

The error details if available.

innererror

InnerError

InnerError
Inner error as defined in the Microsoft REST guidelines (https://github.com/microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses).

message

string

The message of this error.

target

string

The location where the error happened if available.

ErrorCode

ErrorCode

Name Type Description
conflict

string

The requested operation conflicts with the current resource state.

contentFilter

string

Image generation failed as a result of our safety system.

fileImportFailed

string

Import of file failed.

forbidden

string

The operation is forbidden for the current user/api key.

internalFailure

string

Internal error. Please retry.

invalidPayload

string

The request data is invalid for this operation.

itemDoesAlreadyExist

string

The item does already exist.

jsonlValidationFailed

string

Validation of jsonl data failed.

notFound

string

The resource is not found.

quotaExceeded

string

Quota exceeded.

serviceUnavailable

string

The service is currently not available.

tooManyRequests

string

Too many requests. Please retry later.

unauthorized

string

The current user/api key is not authorized for the operation.

unexpectedEntityState

string

The operation cannot be executed in the current resource's state.

ErrorResponse

ErrorResponse

Name Type Description
error

Error

Error
Error content as defined in the Microsoft REST guidelines (https://github.com/microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses).

FineTuningJobCheckpoint

FineTuningJobCheckpoint

Name Type Description
created_at

integer

The Unix timestamp (in seconds) for when the checkpoint was created.

fine_tuned_model_checkpoint

string

The name of the fine-tuned checkpoint model that is created.

fine_tuning_job_id

string

The name of the fine-tuning job that this checkpoint was created from..

id

string

The identity of this checkpoint.

metrics

object

Dictionary`2
The metrics at the step number during the fine-tuning job.

object

TypeDiscriminator

TypeDiscriminator
Defines the type of an object.

step_number

integer

The step number that the checkpoint was created at.

FineTuningJobCheckpointList

FineTuningJobCheckpointList

Name Type Description
data

FineTuningJobCheckpoint[]

The list of items.

has_more

boolean

A value indicating whether the list contains more elements than returned.

object

TypeDiscriminator

TypeDiscriminator
Defines the type of an object.

InnerError

InnerError

Name Type Description
code

InnerErrorCode

InnerErrorCode
Inner error codes as defined in the Microsoft REST guidelines (https://github.com/microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses).

innererror

InnerError

InnerError
Inner error as defined in the Microsoft REST guidelines (https://github.com/microsoft/api-guidelines/blob/vNext/Guidelines.md#7102-error-condition-responses).

InnerErrorCode

InnerErrorCode

Name Type Description
invalidPayload

string

The request data is invalid for this operation.

TypeDiscriminator

TypeDiscriminator

Name Type Description
file

string

This object represents a file.

fine_tuning.job

string

This object represents a fine tune job.

fine_tuning.job.checkpoint

string

This object represents a checkpoint of a fine tuning job.

fine_tuning.job.event

string

This object represents an event of a fine tuning job.

list

string

This object represents a list of other objects.

model

string

This object represents a model (can be a base model or fine tune job result).