Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/openai_deno/mod.ts>OpenAI#createFineTune

OpenAI API wrapper for deno.
Latest
method OpenAI.prototype.createFineTune
Deprecated
Deprecated

OpenAI recommends transitioning to the updating fine-tuning API

import { OpenAI } from "https://deno.land/x/openai_deno@v0.9.8/mod.ts";

Creates a job that fine-tunes a specified 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.

Learn more about Fine-tuning

Parameters

trainingFile: OpenAIFile | string

The ID of an uploaded file that contains training data.

See OpenAI#uploadFile for how to upload a file.

Your dataset must be formatted as a JSONL file, where each training example is a JSON object with the keys "prompt" and "completion". Additionally, you must upload your file with the purpose fine-tune.

See the fine-tuning guide for more details.

optional
params: CreateFineTuneParams

Optional parameters for the API.

Returns

Promise<FineTune>

The fine-tune job.