$client = OpenAI::client($yourApiKey); $message[] = [ "role" => "system", "content" => "ωοτγϣοϓͷઆ໌จΛ࡞Ε·͢" ]; $message[] = [ "role" => "assistant", "content" => "మಓܕ ৽ܕ͘ 273ܥ Nήʔδ 10,000ԁ" ]; $message[] = [ "role" => "user", "content" => "આ໌จΛৄ͘͠1000จࣈఔͰ࡞͍ͯͩ͘͠͞" ]; $response = $client->chat()->create([ 'model' => 'gpt-3.5-turbo', 'messages' => $message ]); foreach ($response->choices as $result) { echo $result->message->content; } echo "\n" . (0.000001 * $response->usage->promptTokens + 0.000002 * $response->usage->completionTokens);