Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cache model in the website #29

Open
thewh1teagle opened this issue Sep 4, 2024 · 6 comments
Open

Cache model in the website #29

thewh1teagle opened this issue Sep 4, 2024 · 6 comments

Comments

@thewh1teagle
Copy link
Contributor

The website nakdimon.org reloads the model each time I open it.
Could you implement caching for the model to avoid this?

Also, it might be more lightweight and faster to run it using onnxruntime, which has an npm package available.

@elazarg
Copy link
Owner

elazarg commented Sep 4, 2024

I trust the default cache implemented in the browser; on my machine it is only downloaded once. Did you disable cache by any chance?
image

@thewh1teagle
Copy link
Contributor Author

I trust the default cache implemented in the browser; on my machine it is only downloaded once. Did you disable cache by any chance?

Interesting. I don't know if something changed but suddenly It does load it from cache. though, multiple times today it was stuck on loading, and just before create the issue I checked and it was load the model... I'll check later again to see if it happens again

@elazarg
Copy link
Owner

elazarg commented Sep 4, 2024

@thewh1teagle
Copy link
Contributor Author


It loaded again the model today (and every few hours)
Seems like it cache the model only for 4 hours.

@elazarg
Copy link
Owner

elazarg commented Sep 5, 2024

I have updated the browser cache TTL to 8 days.

@thewh1teagle
Copy link
Contributor Author

I can see that it's updated. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants