For my app I have one “master” assistant and a dedicated thread per user, so each user has their own context/experience.
So I was reading the docs and saw you can upload a maximum of 20 files per assistant. Initially I thought this therefore means that over all users, a maximum of 20 files can be uploaded across all threads in total, as all threads sit under the one assistant, as this assistant has a max file limit of 20.
HOWEVER, I did some testing by uploading 22 simple, unique text files in a single thread. I expected an error to occur whilst trying to create a message with the 21st file attached to it. However, all 22 uploaded successfully. See the image below: I simply print out all the file_ids I have in the thread.
I then uploaded 50 more text files just to be sure. There’s over 70 messages created in this thread each with a unique text file uploaded with it. All have been successfully uploaded.
So it turns out you can do more than 20? I’m so confused. Do you know why? I had a thought as to maybe why it’s possible. I remember reading somewhere that threads are independent to assistants – that is, multiple assistants can act on a given thread (one at a time, that is). Is it therefore the case that because threads are not a subset of a given assistant, and that they’re their own thing, they do not have a limit as to how many messages with files attached & uploaded with them can be sent in a thread? And that the “20 file limit” is specifically referring ONLY to attaching files at the assistant level – attaching a file when creating an assistant?
Is this correct? Quite confused here.
Thanks!
The link in the docs that prompted my anxiety: