mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-02-25 03:44:09 +01:00
fix(OpenAIClient): use official SDK to identify client and avoid false Rate Limit Error (#1161)
* chore: add eslint ignore unused var pattern * feat: add extractBaseURL helper for valid OpenAI reverse proxies, with tests * feat(OpenAIClient): add new chatCompletion using official OpenAI node SDK * fix(ci): revert change to FORCE_PROMPT condition
This commit is contained in:
parent
ed3d7c9f80
commit
5ab9802aa9
10 changed files with 297 additions and 12 deletions
|
|
@ -86,7 +86,7 @@ describe('OpenAIClient', () => {
|
|||
|
||||
client.setOptions({ reverseProxyUrl: 'https://example.com/completions' });
|
||||
expect(client.completionsUrl).toBe('https://example.com/completions');
|
||||
expect(client.langchainProxy).toBeUndefined();
|
||||
expect(client.langchainProxy).toBe(null);
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue