HackGPT icon indicating copy to clipboard operation
HackGPT copied to clipboard

FileNotFoundError: No secrets files found. Valid paths for a secrets.toml file are: /root/.streamlit/secrets.toml, /app/.streamlit/secrets.toml

Open 71walceli opened this issue 1 year ago • 4 comments

Hi! I just wanted to test it out, and I got this error:

Screenshot_20240305_194610

This is run locally, right? Or do I require some sort of key?

71walceli avatar Mar 06 '24 00:03 71walceli

Same issue here. The error apparently blocks all the functionality.

jurajdanis avatar Apr 04 '24 05:04 jurajdanis

Is it possible and feasible to run this locally? Or this only works with the OpenAI LLM?

71walceli avatar Apr 04 '24 05:04 71walceli

Anyways, I would like to know the correct way to set up a key, I'll help write the instructions for this, though I haven't been able to figure out how...

71walceli avatar Apr 04 '24 05:04 71walceli

1) Secrets file

An example of the secrets file can be found at ./app/.streamlit/secrets.toml.example:

OPENAI_API_KEY = "<YOUR API KEY HERE>"

This file should be copied or renamed to secrets.toml and contain your own OpenAI API key.

Keep in mind that even though it looks like it's running locally, you're still using OpenAI's API, so requests are sent over the internet and there's actually no LLM running locally.

2) Running an LLM locally

If you want to run an LLM locally, check out this repo I created just a few days ago: https://github.com/ricardobalk/streamlit-ollama - not as fancy as this Streamlit app, but it provides a basic setup allowing to run llama2/llama3 locally.

ricardobalk avatar Apr 24 '24 21:04 ricardobalk