AllYourBot / hostedgpt

An open version of ChatGPT you can host anywhere or run locally.
MIT License
269 stars 111 forks source link

Allows for shared, default API keys. #399

Closed matthewbennink closed 4 weeks ago

matthewbennink commented 4 weeks ago

If either of the default ENV keys are set, then the user will have access without needing to provide their own API key(s). I haven't added any tests and this doesn't protect anyone who adds these ENV variables while also allowing users to freely register. Is this simple enough?

Would it be worth adding anything to the README or might it be better to wait until the "feature" is more mature, perhaps allowing for the secrets to be managed within the database, for instance, since that would better support other LLMs outside of OpenAI and Anthropic.

Relates to #236.

matthewbennink commented 4 weeks ago

@krschacht - I've made the requested changes. I wasn't sure if we needed the features ENV variables inside docker-compose.yml as well, but I think we do since we may want to enable/disable features via the host env variables. Let me know what else needs done.