diff --git a/OpenAI_API/Chat/Conversation.cs b/OpenAI_API/Chat/Conversation.cs index a8be8dd..10e7263 100644 --- a/OpenAI_API/Chat/Conversation.cs +++ b/OpenAI_API/Chat/Conversation.cs @@ -190,7 +190,7 @@ public async IAsyncEnumerable StreamResponseEnumerableFromChatbotAsync() { if (res.Choices.FirstOrDefault()?.Delta is ChatMessage delta) { - if (delta.Role != null) + if (responseRole == null && delta.Role != null) responseRole = delta.Role; string deltaContent = delta.Content;