feat: implement thinking for some more copilot models (#234)

Signed-off-by: StarLight842 <mail@aadishv.dev>
This commit is contained in:
Aadish Verma 2025-12-18 19:42:23 -08:00 committed by GitHub
parent bab5cddd4d
commit 314ef34ebc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 49 additions and 16 deletions

View file

@ -194,7 +194,7 @@ export const streamOpenAICompletions: StreamFunction<"openai-completions"> = (
// Some endpoints return reasoning in reasoning_content (llama.cpp),
// or reasoning (other openai compatible endpoints)
const reasoningFields = ["reasoning_content", "reasoning"];
const reasoningFields = ["reasoning_content", "reasoning", "reasoning_text"];
for (const field of reasoningFields) {
if (
(choice.delta as any)[field] !== null &&