You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`REQUEST_TIMEOUT_MS`| string | Main model request timeout in milliseconds. `0` disables the timeout |
51
+
|`MAX_RETRIES`| string | Maximum retry count for transient main model request failures |
48
52
|`<any other KEY>`| string | Custom environment variable |
49
53
50
54
#### `thinkingEnabled` — Thinking Mode
@@ -129,6 +133,22 @@ For detailed MCP usage instructions, refer to [mcp.md](mcp.md).
129
133
130
134
Set to `true` to enable detailed debug logging (default `false`), useful for troubleshooting API calls and tool execution.
131
135
136
+
#### `requestTimeoutMs` and `maxRetries` — Request Timeout and Retries
137
+
138
+
Controls timeout and automatic retries for main model Chat Completion requests:
139
+
140
+
```json
141
+
{
142
+
"requestTimeoutMs": 300000,
143
+
"maxRetries": 2
144
+
}
145
+
```
146
+
147
+
-`requestTimeoutMs` is in milliseconds. The default `0` disables request timeout so long thinking or long outputs are not interrupted unexpectedly.
148
+
-`maxRetries` defaults to `2` and is capped at `10`. Retries apply only to transient failures, such as network disconnects, request timeouts, HTTP `408`, `409`, `425`, `429`, and `5xx`.
149
+
- User interrupts, permission denials, HTTP `400`, `401`, `403`, `404`, and other request/configuration errors are not retried.
150
+
- You can also configure these through environment variables: `DEEPCODE_REQUEST_TIMEOUT_MS=300000`, `DEEPCODE_MAX_RETRIES=2`.
151
+
132
152
## Environment Variable Priority
133
153
134
154
Environment variables are a common way to configure applications, especially for sensitive information (such as api-key) or settings that may change between environments.
@@ -181,4 +201,4 @@ Applied in the following priority order (lower-numbered overridden by higher-num
0 commit comments