rodion-m / ChatGPT_API_dotnet

OpenAI, Azure OpenAI and OpenRouter Chat Completions (ChatGPT) .NET integration with DI, persistence and streaming support
MIT License
77 stars 14 forks source link

Using ChatGPT.CreateInMemoryChat, add response on ChatGPT's behalf? #6

Closed shaneshuford closed 1 year ago

shaneshuford commented 1 year ago

Using the example here, which uses CreateInMemoryChat(): https://github.com/rodion-m/ChatGPT_API_dotnet/blob/master/samples/ChatGpt.ConsoleExample/Program.cs

Is there a way to "inject" a response on GPT's behalf in the middle of a conversation?

For example, a user is having a conversation with GPT, and based on one of their inputs we want to give our own response, but pass that response to GPT so that it knows that was it's last response.

shaneshuford commented 1 year ago

Used Dialog(); instead.