We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c6e7713 commit e58bc70Copy full SHA for e58bc70
src/Services/Proofread/OpenAiService.php
@@ -69,13 +69,15 @@ public function proofreadAllWithConcurrency(array $texts): array
69
{
70
$prompt = $this->prompt;
71
72
+ $model = $this->model;
73
+
74
$tasks = collect($texts)
75
->chunk($this->chunk)
- ->map(function ($chunk) use ($prompt) {
76
+ ->map(function ($chunk) use ($model, $prompt) {
77
- return function () use ($prompt, $chunk) {
78
+ return function () use ($model, $prompt, $chunk) {
79
$response = static::makeClient()->chat()->create([
- 'model' => $this->model,
80
+ 'model' => $model,
81
'response_format' => ['type' => 'json_object'],
82
'messages' => [
83
[
0 commit comments