Chainlit / chainlit

Build Conversational AI in minutes ⚡️
https://docs.chainlit.io
Apache License 2.0
7.18k stars 943 forks source link

Request: File Upload Cotent behavior #768

Open JCF-SES opened 8 months ago

JCF-SES commented 8 months ago

Python 3.10 and 3.11 Chainlit 1.0.301

In previous versions File uploads used to be passed in bytes content only. Now this is being passed as a path only (all my test have None for content so far, maybe I'm missing something).

I use the file upload modality for users to upload documents, which are piped to a vector store. I used the byte content to save the files to a temporary directory, wiped out after processing. Not for multimodal LLM cases.

These files are now persistent in the .files path (Again, am I missing something), which are to be sincere, just bloating my deployment.

Can this behavior be configurable somehow? I didn't see anything in the documentation site and getting byte data from .content made more sense to me.

Hope this makes sense for the long run.

Best, JC

adityapatil1010 commented 3 months ago

which previous versions pass in bytes content only.