SafeNote
SafeNote (Safe Notebook) is a tool for injecting your secrets into Jupyter notebooks environment safer and easier.
Last updated
SafeNote (Safe Notebook) is a tool for injecting your secrets into Jupyter notebooks environment safer and easier.
Last updated
Sharing notebook is very common within a research group, and even with public. It is very important to protect your secret from being used without your intention, especially for those API Keys that charge a lot (e.g. OpenAI API Key). SafeNote will inject your variables into environment every time, which means that people never get your secret with your notebook sharing link.
For the future? We are currently planning a SaaS product that helps team reducing the time they need to copy, paste, or type in their environment values. It will also be delivered with this package.
Simple, right?
Then, env
variable will contain all values you input while prompting. And all these keys will be populated into os.environ
for the usage of other packages (e.g. LangChain).
You can also use variables OPENAI_API_KEY
and SERPER_API_KEY
directly.
We are still working on the SaaS solution that helps you remember your secret at a safe place and prevents them from being mis-used.
You can actually pass key
argument into the request
function!
Then, you don't actually need the return value.
os.environ
?Just set inject_env
to False
.
We currently are relying on global variables for the population of those secrets. Therefore, you are unable to avoid injecting them into global variables at this point. However, this is one of our goals in a sooner future that we will make it more secure, and therefore you will be able to reject to assign global variables from SafeNote.