Open
Description
Service
OpenAI
Describe the bug
For a CompleteChatStreamingAsync request the property StreamingChatCompletionUpdate.FinishReason is always null
. Stop is expected when the response has been transmitted in full or length when the maximum number of tokens per request has been reached.
In comparison, ChatCompletion.FinishReason is set correctly when using CompleteChatAsync.
Steps to reproduce
Set ChatCompletionOptions.MaxOutputTokenCount to a value that is less than the tokens required for the response and make a request using CompleteChatStreamingAsync.
Code snippets
OS
Windows 10
.NET version
.NET 9.0
Library version
OpenAI 2.1.0