provider: add Gonka Broker#1699
Open
iamoeco wants to merge 1 commit into
Open
Conversation
Author
|
Hi @VisargD @narengogi — gentle bump 🙏 The only pending check is the first-contributor CI gate awaiting a maintainer's "approve and run". The PR mirrors the existing lambda provider (4 files, pure pass-through, mergeable). Could you approve the run and take a look? Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description: (required)
open-ai-basechat/completion params and response transformers, mirroring the existinglambdaprovider.src/providers/gonkabroker/api.tssets the base URLhttps://proxy.gonkabroker.com/v1, aAuthorization: Bearerheader, and/chat/completions+/completionsendpoint mapping.src/providers/gonkabroker/index.tswireschatCompleteandcompleteviaopen-ai-base. No default model is baked in: the provider is a pure pass-through, so the inheritedopen-ai-basedefault (gpt-3.5-turbo) is cleared with{ model: undefined }. An omitted model then returns a clean error from the upstream API instead of silently routing to a model the provider does not serve. Model identity belongs to the caller.GONKABROKERconst +VALID_PROVIDERSentry insrc/globals.ts, and the import + provider-map entry insrc/providers/index.ts.Tests Run/Test cases added: (required)
npm run dev:node) with a real API key.POST /v1/chat/completionswithx-portkey-provider: gonkabrokerreturned HTTP 200 with a valid OpenAI-shaped completion ("provider":"gonkabroker").modelreturns an error from the provider rather than routing to a default model, confirming the pass-through behavior.npm run format:checkpasses;npm run buildsucceeds.Type of Change: