亮色模式
Create fine-tuning job
POST
https://api.openai.com/v1/fine_tuning/jobsCreates a fine-tuning job which begins the process of creating a new model from a given dataset.
Response includes details of the enqueued job including job status and the name of the fine-tuned models once complete.
Request
Header 参数
Content-Type
string
必需
示例值:
application/json
Authorization
string
必需
示例值:
Bearer $OPENAI_API_KEY
Body 参数application/json
training_file
string
必需
The ID of an uploaded file that contains training data.
See upload file for how to upload a file.
Your dataset must be formatted as a JSONL file. Additionally, you must upload your file with the purpose fine-tune
.
The contents of the file should differ depending on if the model uses the chat or completions format.
See the fine-tuning guide for more details.
model
string
必需
The name of the model to fine-tune. You can select one of the supported models.
示例
{
"training_file": "file-BK7bzQj3FfZFXr7DbL6xJwfo",
"model": "gpt-4o-mini"
}
Request samples
返回响应
Success(200)
HTTP Code: 200
Content Type : JSONapplication/json
数据结构
object
string
必需
id
string
必需
model
string
必需
created_at
integer
必需
fine_tuned_model
null
必需
organization_id
string
必需
result_files
array[string]
必需
status
string
必需
validation_file
null
必需
training_file
string
必需
示例
{
"object": "fine_tuning.job",
"id": "ftjob-abc123",
"model": "gpt-4o-mini-2024-07-18",
"created_at": 1721764800,
"fine_tuned_model": null,
"organization_id": "org-123",
"result_files": [],
"status": "queued",
"validation_file": null,
"training_file": "file-abc123",
}
最后修改时间: 10 天前