Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added docs for OpenAI-compatibles APIs support #450

Merged
merged 2 commits into from
Nov 18, 2023

Conversation

kristaller486
Copy link
Contributor

The OpenAI python lib already supports changing the API_BASE, but I think it would be useful to note this in the README and .env.example

@n3d1117
Copy link
Owner

n3d1117 commented Nov 16, 2023

Thanks @kristaller486, I didn't know this. Have you tested it and does it actually work? I don't have any 3rd party APIs and I have no way of checking

@kristaller486
Copy link
Contributor Author

Yes, I tested it with an OpenAI-compatible API for open-source LLM, such as text-generation-webui and llama.cpp server api_like_OAI. I think it will work with any other openai-compatible APIs.

@n3d1117
Copy link
Owner

n3d1117 commented Nov 18, 2023

Great thanks @kristaller486, lgtm!

@n3d1117 n3d1117 merged commit 40c5907 into n3d1117:main Nov 18, 2023
@gilcu3
Copy link
Contributor

gilcu3 commented Nov 18, 2023

Hi, sorry for the dumb question but where/how is exactly the new constant OPENAI_API_BASE used in the code? I only see it in config and docs.

@n3d1117
Copy link
Owner

n3d1117 commented Nov 18, 2023

Hi @gilcu3 not a dumb question at all. It's renamed to OPENAI_BASE_URL (fixed) and it is used internally in the openai-python lib :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants