-
Notifications
You must be signed in to change notification settings - Fork 8
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
Feat/wrapper #40
Feat/wrapper #40
Conversation
tests/images/openai.test.ts
Outdated
}, 120000); | ||
|
||
|
||
// test('model: gpt-4-1106-preview', async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove comments if they are not required. From other files as well.
|
||
config({ override: true }) | ||
const client = new Portkey({ | ||
apiKey: process.env["PORTKEY_API_KEY"] ?? "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the DEV base url. We can use the default PROD url for testing SDKs.
…ged, BASE URL changed
src/apis/images.ts
Outdated
|
||
export interface ImagesBody { | ||
prompt: string; | ||
model?: (string & {}) | "dall-e-2" | "dall-e-3"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we change this to just a normal string type?
src/apis/images.ts
Outdated
n?: number | null; | ||
quality?: "standard" | "hd"; | ||
response_format?: "url" | "b64_json" | null; | ||
size?: "256x256" | "512x512" | "1024x1024" | "1792x1024" | "1024x1792" | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these required or can we just make it a string?
src/apis/images.ts
Outdated
quality?: "standard" | "hd"; | ||
response_format?: "url" | "b64_json" | null; | ||
size?: "256x256" | "512x512" | "1024x1024" | "1792x1024" | "1024x1792" | null; | ||
style?: "vivid" | "natural" | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can also just be a string as other providers might have different styles
@csgulati09 - We should try to make our interfaces as flexible as possible because Portkey SDK will be used for providers other than openai as well. Have added a few comments related to this. But the broader idea is to keep things open-ended for input params so that if the values are different for other providers, it does not break for them |
src/apis/threads.ts
Outdated
metadata?: unknown | null; | ||
} | ||
|
||
export namespace ThreadCreateParams { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this required?
Closes #38 |
Title: Revamp: wrapper around OpenAI SDK (Hybrid)
Description:
Motivation:
This will make it easier for us to integrate newly introduced routes from OpenAI
Related Issues:
#38