-
Notifications
You must be signed in to change notification settings - Fork 170
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
update: headers info with functions (Chat + Audio + Completion) #211
base: main
Are you sure you want to change the base?
Conversation
Hello @Krobys, thank you so much for your valuable contribution! I appreciate your idea, and I think we should adopt the following structure: package com.aallam.openai.api.core
data class OpenAIResponse<T>(val headers: Map<String, List<String>>, val body: T) This serves two main purposes:
Regarding the method naming, I suggest we use the prefix Once again, thank you for your insights and contributions. They are greatly appreciated! |
is it worth changing the old methods to return a new object or adding paired similar methods methods as I did and not touching the old ones for compatibility |
You're correct, changing the old methods would introduce a breaking change. We would need to wait for a major release to implement that. In the meantime, adding new methods, as you've done, should suffice and maintain compatibility. |
497f54f
to
fcfd8b7
Compare
ba88d2a
to
91f971a
Compare
Describe your change
Added two new methods to Chat and Audio, so now two new functions available for getting response with headers. Also updated sample to test new features
What problem is this fixing?
No headers info was available with default response