fix: add store:false to Chat Completions and /responses fallback (#578)
Set store: false in the request body for both the Chat Completions path and the /responses fallback path in openaiShim.ts. The codexShim (Responses API primary path) already sets store: false. The Chat Completions path and the /responses fallback in openaiShim were missing it. store: false tells the API provider not to persist conversation data for model training, logging, or other non-operational purposes. This is a privacy measure — it does not affect caching or functionality. Note: Whether third-party proxies (e.g. GitHub Copilot) honour this parameter is provider-dependent, but setting it is a reasonable default for user privacy. Co-authored-by: Zartris <14197299+Zartris@users.noreply.github.com>
This commit is contained in:
@@ -1184,6 +1184,7 @@ class OpenAIShimMessages {
|
|||||||
model: request.resolvedModel,
|
model: request.resolvedModel,
|
||||||
messages: openaiMessages,
|
messages: openaiMessages,
|
||||||
stream: params.stream ?? false,
|
stream: params.stream ?? false,
|
||||||
|
store: false,
|
||||||
}
|
}
|
||||||
// Convert max_tokens to max_completion_tokens for OpenAI API compatibility.
|
// Convert max_tokens to max_completion_tokens for OpenAI API compatibility.
|
||||||
// Azure OpenAI requires max_completion_tokens and does not accept max_tokens.
|
// Azure OpenAI requires max_completion_tokens and does not accept max_tokens.
|
||||||
@@ -1358,6 +1359,7 @@ class OpenAIShimMessages {
|
|||||||
}>,
|
}>,
|
||||||
),
|
),
|
||||||
stream: params.stream ?? false,
|
stream: params.stream ?? false,
|
||||||
|
store: false,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!Array.isArray(responsesBody.input) || responsesBody.input.length === 0) {
|
if (!Array.isArray(responsesBody.input) || responsesBody.input.length === 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user