feat: Support custom headers and pre-request auth hooks for OpenAI-compatible providers#120
feat: Support custom headers and pre-request auth hooks for OpenAI-compatible providers#120qznc wants to merge 4 commits into
Conversation
Just for OpenAI-compatible providers. Partially fixes graniet#119
Just for OpenAI-compatible providers. Partially fixes graniet#119
|
Unit tests are passing, but I haven't done any real testing yet. |
|
It does work in practice and well enough for my purposes, so it is ready from my point of view. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 337ad7dd80
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
I'm interested in seeing this merged, but I'm wondering if a simpler (ie lower surface area to review) approach might be to selectively add this feature only to backends that are likely to be used with other providers (eg OpenAI, which most providers are compatible with and perhaps Anthropic which at least MiniMax has a compatible API for, although they do support OpenAI too). The reason being that the normal backends don't require it, only if you piggyback a different provider on one. Another approach is to make new backends |
Fixes #119