Capture the reasoning content in base-openai-compatible for GLM 4.6 (#8976)

This commit is contained in:
Matt Rubens 2025-11-02 01:00:33 -04:00 committed by GitHub
parent d7ea6d679e
commit 388d40524d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -115,6 +115,10 @@ export abstract class BaseOpenAiCompatibleProvider<ModelName extends string>
}
}
if (delta && "reasoning_content" in delta && delta.reasoning_content) {
yield { type: "reasoning", text: (delta.reasoning_content as string | undefined) || "" }
}
if (chunk.usage) {
yield {
type: "usage",