How to tell GPT to retrieve files for different purpose

My question is:

If I have two files, file_0 and file_1, where the content of file_0 serves as examples for the prompt, and file_1 contains the data I want GPT to analyze, how can I instruct GPT to use file_0 as examples and then analyze file_1?

Thank you to anyone who takes the time to help me with my question. I appreciate your assistance!

Hi and welcome to the Developer Forum!

What have you tried so far?

Try naming the files something like “examples for analysis” and “to analyze”. It would be interesting to see if we can use the filenames as additional prompt parameters.

You would have the play around with it. Rememeber when instructing the GPT less is more. Pretend this is a new employee you want to do something perfectly and break it down for them in their instructions:

"You are now an advanced file analyist. Attached are two files file_0 and file_1 your purpose is to review the example template parameters in file_0 and use these parameters to analyize file_1. Proceed by doing the following:



I found what works is
/giveInterviewQuestion - calls code-interpretor loads up and chooses a random example and outputs that to the console, then you ask that example to the user. eval(“”.read()+“selectRandom()”)

Jumping in here because I’m having the same issue and I’ve tried the recommendations listed here without a lot of success.

In my case, I have 3 CSV files with different data sources. Each file is named simply. For example: people.csv, events.csv, and purchases.csv.

Yet, when I interact with the Assistant in the API Playground and ask about events, it repeatedly pulls up the people.csv file first and then has to go back and forth about “Oops, wrong file. Let me check another.”

Any suggestions for how I can train it to be smarter about this?

You can upload both your files and just tell the assistant to use file_0 for prompt and file_1 for content. Here is an example of it working in a colab notebook. I asked my assistant to have some humor in the response. It does work.