However, I see that variables directory has too much of data (nearly 145 MB) which makes it nearly difficult to save in my Github repo. Github allows only files of size 25 MB if I am not wrong.
I think your best bet is to save the model weights to a cloud storage service such as Google Drive / Dropbox / S3 bucket. You can then download and cache the weights in your app. Here’s a similar solution from @metasemantic How to download large model files to the sharing app? - #5 by metasemantic
@SimonBiggs was even able save model weights within a Github release which was then downloaded within the Streamlit app How to download large model files to the sharing app? - #18 by SimonBiggs
If I’m not mistaken, we also support Git LFS on Streamlit Sharing. You could use Git LFS to store the ~ 145 MB file on Github.
Best,
Snehan