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

[Feat]: Using Safetensors instead of Pickle Libraries for security purposes #191

Closed
cogspot opened this issue Jan 29, 2025 · 1 comment
Closed
Labels
enhancement New feature or request

Comments

@cogspot
Copy link

cogspot commented Jan 29, 2025

Description
There are inherent risks of locally hosting models especially from China since CCP requires, by law, that software must be backdoored. PyTorch models are loaded using a serialization library called Pickle, which creates a virtual machine very briefly during the process of loading model weights. It is possible to hide malicious code inside the pickle library, which then executes upon the VM being created. SafeTensors allows you to mitigate this security risk.

Use Case
Securely offload and load locally hosted models

@cogspot cogspot added the enhancement New feature or request label Jan 29, 2025
@a-ghorbani
Copy link
Owner

Could you point out where we mentioned that we are using Pickle?

PocketPal AI uses the GGUF format: https://huggingface.co/docs/hub/en/gguf

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

No branches or pull requests

2 participants