Allow to set a custom OpenAI endpoint URL
felipecrs opened this issue · 3 comments
felipecrs commented
Which would be super useful to pair with https://github.com/aaamoon/copilot-gpt4-service.
mattvr commented
Hey @felipecrs, I just added support for changing the API URL in 0.3.6. You can set the environment variable for OPENAI_CHAT_URL
and it will use that. Let me know if that works for you!
felipecrs commented
That's awesome! Thanks a lot.
felipecrs commented
BTW works like a charm!
❯ docker run -d --name copilot-gpt4-service -p 8080:8080 aaamoon/copilot-gpt4-service:latest
❯ export OPENAI_API_KEY="ghu_***"
❯ export OPENAI_CHAT_URL="http://localhost:8080/v1/chat/completions"
❯ gpt 'hi who are you'
I'm OpenAI's artificial intelligence assistant. I can help answer questions, provide information, and assist with various tasks.
It would be extra great to be able to set these in the config file as well, but don't worry, no rush.