When I upload a file in my assistant, how is the context handled?


I’ve been using ChatGPT assistant api since it was launched and I have a question about how the context is handled during a conversation with a user when we link a file to an assistant using the code interpreter.

I use the API for a custom chat, that is able to answer user’s questions about a csv I pass as a file argument when I instantiate the assistant.
I only used the code interpreter so far, as the retrieval (and vector search) does not seem to perform well for the task I want to perform (but I’m a beginner so maybe I got it wrong).

The CSV data I load in my assistant is made of several rows, each representing the response of a person to a specific survey. It works well but at time, ChatGPT seems to forget the context and seems to answer questions only using the first rows of the csv.

So I wonder how the assistant maintains the context during a conversation. Any idea where I could find more information about that? And maybe ways to monitor and improve this?

Many many thank you!

1 Like