I was having the same SSL Certificate Verification Failed error when using HuggingFaceEmbeddings(model_name="sentence-transformers/all-MiniLM-L6-v2")
Error Message:
SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain
To fix the problem, I downloaded the ROOT_CA on my company laptop (check how to do it in this reply, follow only step#1), exported it as a .pem file, and in the main() function of my python script, set the ‘CURL_CA_BUNDLE’ environment variable to the ROOT_CA.pem, as follows:
os.environ['CURL_CA_BUNDLE'] = /path/to/extracted/ROOT_CA.pem
PS: python 3.9.13, requests==2.32.3