mirror of
https://github.com/Nezumi-2711/9router.git
synced 2026-09-22 13:38:31 +00:00
fix(commandcode): force stream=true in transformRequest
CommandCode upstream only speaks NDJSON streaming; the executor always wraps it as OpenAI SSE. Force body.stream=true so non-stream client requests still produce a parseable upstream stream (router aggregates SSE→JSON downstream). Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
committed by
decolua
co-authored by
Cursor
parent
137a25e9ac
commit
c5815ad3f0
@@ -19,6 +19,11 @@ export class CommandCodeExecutor extends BaseExecutor {
|
||||
super("commandcode", PROVIDERS.commandcode);
|
||||
}
|
||||
|
||||
transformRequest(model, body, stream, credentials) {
|
||||
body.stream = true;
|
||||
return body;
|
||||
}
|
||||
|
||||
buildHeaders(credentials, stream = true) {
|
||||
const headers = {
|
||||
"Content-Type": "application/json",
|
||||
|
||||
Reference in New Issue
Block a user