OpenAI assistant InvokeStreamingAsync - chat history #8810
-
Hi team Why is chat history mandatory when we invoke OpenAi Assistant.InvokeStreamingAsync - the first parameter is threadId - why do we need to keep chat history? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
@crickman - can you take a look at this for .NET? |
Beta Was this translation helpful? Give feedback.
-
Hi @JP-droidic, thank you for calling this out. Two scenarios require maintaining the non-streamed history: Now that you've called it out, I realize that for this no-chat invocation case...its only a convenience and not required. I can certainly make it optional. I like have the option available as a convenience since we know some customers cases involve examining the history...even for streaming. Forcing the caller to build history from streaming content can be tedious so maintaining this as an option can be helpful for these cases. |
Beta Was this translation helpful? Give feedback.
Hi @JP-droidic, thank you for calling this out.
Two scenarios require maintaining the non-streamed history:
ChatCompletionAgent
andAgentChat
. TheAgentChat
case extends to bothChatCompletionAgent
andOpenAIAssistantAgent
. This focus, resulted in the presence of the history parameter to which you are referring.Now that you've called it out, I realize that for this no-chat invocation case...its only a convenience and not required. I can certainly make it optional.
I like have the option available as a convenience since we know some customers cases involve examining the history...even for streaming. Forcing the caller to build history from streaming content can be tedious so maintaining t…