bit-gpt / app

BitGPT it's your personal AI in your pocket
https://bitgpt.network
MIT License
458 stars 40 forks source link

bug: downloaded dynamic state for services without verification for binaries #425

Open swarnimarun opened 1 year ago

swarnimarun commented 1 year ago

Issue:

Downloaded services are fetched based on just if models are present locally at application start, but not updated before each service run, hence manifests and binary files aren't rechecked if they are actually correct or present locally.

This can currently cause the application to fail without letting the user know of the exact method to fix this issue. (They just need to delete and reinstall it)

The two most likely scenarios are:

Solution

Always check if the files are locally present(we currently do check for weights, on prem-app startup, but we don't do this for binaries at all) and if the checksums are upto date(#423), before starting the service. And forward meaningful error messages to the user.

Janaka-Steph commented 1 year ago

Downloaded services are marked downloaded in persistent state(zustand)

I don't think this is the case. To which state are you referring to?

Always check if the files are locally present(we currently do this for binaries, but we don't do this for weights)

This is the contrary. is_service_downloaded() is checking for weights but not the binary.

swarnimarun commented 1 year ago

Downloaded services are marked downloaded in persistent state(zustand)

I don't think this is the case. To which state are you referring to?

Always check if the files are locally present(we currently do this for binaries, but we don't do this for weights)

This is the contrary. is_service_downloaded() is checking for weights but not the binary.

  1. Yep you are correct, I confused a zustand state with dynamic state for services.
  2. yea meant to write it the other way around clarified it all a bit.