I submitted batch embedding jobs within the limits mentioned in the documentation. Every job completed successfully and I can see that the files are available:
{
"object":"file",
"id":"file-...",
"purpose":"batch_output",
"filename":"batch_..._output.jsonl",
"bytes":2116946514,
...
"status":"processed",
"status_details":null
}
However, when I try to download the file, I receive a 504 Gateway Timeout error after 1 minute:
curl -i https://api.openai.com/v1/files/file-.../content -H "Authorization: Bearer $OPENAI_API_KEY" > file.jsonl
HTTP/2 504
...
error code: 504
Same happens using the openai
npm package.
I couldn’t find relevant limits mentioned in the API reference. Is there a file size limit for downloading batch output files, or is there a recommended approach for retrieving large outputs?