Open AayushSameerShah opened 10 months ago
Hello!
Although I've used it quite a bit, I'm no flask expert by any means, so take my advice with a grain of salt.
threaded=False
, everything might just be handled sequentially. In practice, you'll run a flask app with e.g. gunicorn with some amount of workers. For each worker, the model would be initialized fresh. This might cause memory issues. Look for recommendations here. This SO post is also useful.
👋🏻 Hello, I know it might sound a little silly to ask, but I am working on a project in which I use flask as the API server and use
sentence-transformers/all-MiniLM-L6-v2
as the model for the similarity check.👨🏻💻 Structure
On the high-level I have the following structure:
app.py
And in the functions.py
🤔 My question
Currently it is working just fine with multiple users, but I am willing to know if it is the standard approach, or anything needs to be changed.
Please guide me on this, Thank you 🙏🏻