quivr icon indicating copy to clipboard operation
quivr copied to clipboard

API_base

Open nimrod1990 opened this issue 1 year ago • 4 comments

I hope to set up API forwarding or set environment variables.

nimrod1990 avatar May 25 '23 19:05 nimrod1990

Can you please provide more details ?

StanGirard avatar May 25 '23 22:05 StanGirard

I want to know if the API Endpoint can be customized. I have an api key, but I want to redirect it to another URL. Should I add it when modifying env?

nimrod1990 avatar May 26 '23 01:05 nimrod1990

API endpoint of openai ? Yes it can but you have to modify the code yourself

StanGirard avatar May 26 '23 08:05 StanGirard

API endpoint of openai ? Yes it can but you have to modify the code yourself

I would like to know if you know how to modify this option? I am a beginner and not quite sure how to proceed. I need to replace “api.openai.com” with “api.chatanywhere.com.cn”. Can I set a global variable like this: “”“ import openai openai.api_base = "https://api.chatanywhere.com.cn/v1" ”“” and where to do that. Thanks! 🤣

nimrod1990 avatar May 26 '23 10:05 nimrod1990