I am trying to understand the best way to setup prompts and the library for an interactive chat session. It looks like based on the InteractiveModeExecute.cs example, the "bob" personality is only described once and then the interactive session runs from that. Wouldn't the concept of bob be lost over time as the conversation goes on?
I am working on a scenario where I have a multi user bot with a defined system prompt that describes the bot's behavior and establishes guidelines on how to respond.
When a person sends a message to the bot, I am using Semantic Kernel and Azure OpenAI to handle a vector search to see if I have any relevant information stored that would apply and help the bot properly respond.
Ultimately, I end up building a larger prompt that includes the system prompt, embedding results text, and finally the user's input. I pass all of this to the InferAsync method of the InteractiveExecutor. This was the only way I could figure out to do it where the model would have all of the data necessary to form a response.
I am not using the ChatSession object for this process since the bot may receive messages from different users and I really don't need the bot to respond based on past messages.
What I am seeing is that I get results for the first executor.InferAsync, but as new messages comes in the InferAsync just results empty results. The only way I have found to stop that from happening is to save off a clean state from the executor once that object is created and then load that state prior to each InferAsync call. That doesn't seem right.
I have tried the StatelessExecutor but I get some really odd results that seem to be crazy ramblings that really don't take much of the full prompt into consideration.
Any thoughts on my approach and what I should do different. I am considering trying to use the ChatSession object and then saving a session off per chat user. When a user sends in a message, I could check to see if there is a past session that could be loaded and continue the conversation from there.
I am trying to understand the best way to setup prompts and the library for an interactive chat session. It looks like based on the InteractiveModeExecute.cs example, the "bob" personality is only described once and then the interactive session runs from that. Wouldn't the concept of bob be lost over time as the conversation goes on?
I am working on a scenario where I have a multi user bot with a defined system prompt that describes the bot's behavior and establishes guidelines on how to respond.
When a person sends a message to the bot, I am using Semantic Kernel and Azure OpenAI to handle a vector search to see if I have any relevant information stored that would apply and help the bot properly respond.
Ultimately, I end up building a larger prompt that includes the system prompt, embedding results text, and finally the user's input. I pass all of this to the InferAsync method of the InteractiveExecutor. This was the only way I could figure out to do it where the model would have all of the data necessary to form a response.
I am not using the ChatSession object for this process since the bot may receive messages from different users and I really don't need the bot to respond based on past messages.
What I am seeing is that I get results for the first executor.InferAsync, but as new messages comes in the InferAsync just results empty results. The only way I have found to stop that from happening is to save off a clean state from the executor once that object is created and then load that state prior to each InferAsync call. That doesn't seem right.
I have tried the StatelessExecutor but I get some really odd results that seem to be crazy ramblings that really don't take much of the full prompt into consideration.
Any thoughts on my approach and what I should do different. I am considering trying to use the ChatSession object and then saving a session off per chat user. When a user sends in a message, I could check to see if there is a past session that could be loaded and continue the conversation from there.