-
-
Notifications
You must be signed in to change notification settings - Fork 170
Open
Description
gemini-cli-openai/src/routes/openai.ts
Lines 37 to 38 in d9dfb02
| // OpenAI API compatibility: stream defaults to true unless explicitly set to false | |
| const stream = body.stream !== false; |
said stream defaults to true if not provided, but openai's official docs said it defaults to false.
And the current behavior also breaks the following code using openai sdk:
import openai
client = openai.OpenAI()
resp = client.chat.completions.create(
model="gemini-2.5-flash",
messages=[{"role": "user", "content": "Hello!"}],
max_tokens=1024,
)
print(resp.choices[0].message.content)
Metadata
Metadata
Assignees
Labels
No labels