How can I connect previous threads when creating a new thread in OpenAI’s API using C#? My goal is to append the last few messages from the previous thread to the new one to maintain conversation history. I’m storing user inputs and responses in Cosmos DB and fetching the latest four messages whenever a new thread is created. Each new user input generates a new thread, and I need to ensure that the previous context is carried over by adding those last four messages to the newly created thread. What is the best way to manage this process efficiently in C# while handling multiple threads and keeping the conversation flow intact?
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
How to Add Chat History in OpenAI Assistant in a C# Bot Framework? | 1 | 163 | September 9, 2024 | |
Adding new messages to assistant threads | 3 | 320 | October 11, 2024 | |
How to reuse previously created thread data in new thread without adding previous thread data to new thread | 0 | 492 | April 19, 2024 | |
How to add conversation history to a thread in Assistants API? | 0 | 147 | July 26, 2024 | |
How can I maintain conversation continuity with chat gpt api? | 9 | 21943 | April 16, 2024 |