Download files from an Action in a GPT

File content (not JSON) returned from an Action is processed directly by the model. Has anyone figured out a way around this? I’ve succeeded with small text files, where GPT will use Python to save the file to disk when I ask it to.

1 Like

Can you say more about this?

Have yuo tried the other way round?

I’m having the same issue. not sure if you’ve resolved the issue.

to elaborate on the issue, see my screenshot:
I created an Action to retrieve stock data from my custom built API.
GPT can download stock metrics with the API.

I can tell that in my screenshot, the GPT retrieved and dumped the raw response as a part of the response. and then it translates the raw csv data into Python variable, instead of storing the csv somewhere and read the file directly, which I prefer.

I suspect that it could be some security concerns to download arbitrary files from the Internet into the sandbox. But I’m also curious: if we download files and make then non-executable, and. read-only, what risks can we have there?

1 Like

I think that is what a json file is supposed to do in the first place. The json can be automatically turned into a .csv . If you DONT want to do that, I have just been using an action that is exactly like browsing the web. It returns the information you ask for, and in very large text, or it can be html. I guess it depends on what file you want. If you are talking scraping without a .json, I have seen it out there, but for my purposes it has not been relevant to look into yet. You can feed that huge file dump, in sliced chunks, to GPT 4, and it will turn it to whatever you want. But it can’t take the whole raw file at once.

Hi, facing the exact same issue. Was wondering if you have been able to find a solution.? Based on my attempts, it seems that OpenAI is now allowing a csv download and just automatically reads the csv sent by my API server and renders it as a JSON.