TsgcHTTP_API_OpenAIMethods › ListFineTuningJobs

ListFineTuningJobs Method

Lists fine-tuning jobs belonging to the authenticated organization with cursor-based pagination

Syntax

function ListFineTuningJobs(const aLimit: Integer = 20; const aAfter: string = '') : TsgcOpenAIClass_Response_List_FineTuningJobs;

Parameters

NameTypeDescription
aLimitconst IntegerMaximum number of jobs to return per page (default 20)
aAfterconst stringIdentifier of the last job in the previous page, used for pagination

Return Value

Paginated list of fine-tuning jobs with HasMore flag (TsgcOpenAIClass_Response_List_FineTuningJobs)

Remarks

Calls the GET /v1/fine_tuning/jobs endpoint. Returns jobs in reverse chronological order (newest first). Use aAfter with the id of the last returned job to fetch the next page. This method targets the current fine-tuning API; for legacy fine-tunes use ListFineTunes instead.

Example

oResponse := oAPI.ListFineTuningJobs(50);
for i := 0 to oResponse.Data.Count - 1 do
  Memo1.Lines.Add(oResponse.Data[i].Id + ' - ' + oResponse.Data[i].Status);

Back to Methods