I upload a file to create a job with official API:
$fineTuned = $client->fineTuning()->createJob([
'training_file' => 'file-bdj...W2',
'validation_file' => null,
'model' => 'gpt-3.5-turbo',
'suffix' => null,
]);
resulting in error:
OpenAI\Exceptions\ErrorException
File file-bdj...W2 has invalid purpose 'fine-tune-results', must be 'fine-tune'
Fatal error: Uncaught OpenAI\Exceptions\ErrorException: File file-bdj...W2 has invalid purpose 'fine-tune-results', must be 'fine-tune' in /.../vendor/openai-php/client/src/Transporters/HttpTransporter.php:131
Stack trace:
#0 /.../vendor/openai-php/client/src/Transporters/HttpTransporter.php(57):
OpenAI\Transporters\HttpTransporter->throwIfJsonError(Array, '{\n "error": {\n...')
#1 /.../vendor/openai-php/client/src/Resources/FineTuning.php(32): OpenAI\Transporters\HttpTransporter->requestObject(Object(OpenAI\ValueObjects\Transporter\Payload))
#2 /.../test.php(15): OpenAI\Resources\FineTuning->createJob(Array) #3 {main} thrown in /.../vendor/openai-php/client/src/Transporters/HttpTransporter.php on line 131
I tried using the api docs.