-
-
Notifications
You must be signed in to change notification settings - Fork 224
/
Copy pathopenai.php
50 lines (41 loc) · 1.73 KB
/
openai.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?php
return [
/*
|--------------------------------------------------------------------------
| OpenAI API Key and Organization
|--------------------------------------------------------------------------
|
| Here you may specify your OpenAI API Key and organization. This will be
| used to authenticate with the OpenAI API - you can find your API key
| and organization on your OpenAI dashboard, at https://openai.com.
*/
'api_key' => env('OPENAI_API_KEY'),
'organization' => env('OPENAI_ORGANIZATION'),
/*
|--------------------------------------------------------------------------
| Request Timeout
|--------------------------------------------------------------------------
|
| The timeout may be used to specify the maximum number of seconds to wait
| for a response. By default, the client will time out after 30 seconds.
*/
'request_timeout' => env('OPENAI_REQUEST_TIMEOUT', 30),
/*
|--------------------------------------------------------------------------
| Maximum Retry Attempt
|--------------------------------------------------------------------------
|
| The retry attempt may be used to specify how many times retry when OpenAI server return error .
| By default, the library will try once.
*/
'max_retry_attempt' => env('OPENAI_RETRY_ATTEMPT', 5),
/*
|--------------------------------------------------------------------------
| Retry Delay
|--------------------------------------------------------------------------
|
| Decides how long after a request should be repeated when a request fails.
| By default, resend the request immediately.
*/
'retry_delay' => env('OPENAI_RETRY_DELAY'),
];