Skip to content
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

OpenAI SDK upgrade #4

Merged
merged 9 commits into from
Oct 15, 2024
Merged

OpenAI SDK upgrade #4

merged 9 commits into from
Oct 15, 2024

Conversation

pigri
Copy link

@pigri pigri commented Oct 15, 2024

A similar PR may already be submitted!
Please search among the Pull request before creating one.

If your changes introduce breaking changes, please prefix the title of your pull request with "[BREAKING_CHANGES]". This allows for clear identification of such changes in the 'What's Changed' section on the release page, making it developer-friendly.

Thanks for submitting a pull request! Please provide enough information so that others can review your pull request.

Describe the change
Please provide a clear and concise description of the changes you're proposing. Explain what problem it solves or what feature it adds.

Provide OpenAI documentation link
Provide a relevant API doc from https://platform.openai.com/docs/api-reference

Describe your solution
Describe how your changes address the problem or how they add the feature. This should include a brief description of your approach and any new libraries or dependencies you're using.

Tests
Briefly describe how you have tested these changes. If possible — please add integration tests.

Additional context
Add any other context or screenshots or logs about your pull request here. If the pull request relates to an open issue, please link to it.

Issue: #XXXX

eiixy and others added 9 commits September 26, 2024 13:25
* update client error return

* update client_test.go

* update client_test.go

* update file_api_test.go

* update client_test.go

* update client_test.go
The json tag is incorrect, and results in an error from the API when using the o1 model.  

I didn't modify the struct field name to maintain compatibility if anyone else had started using it, but it wouldn't work for them either.
* fix spelling error

* fix lint

* Update chat.go

* Update chat.go
* add jailbreak filter result

* add content filter results on completion output

* add profanity content filter
* Completion API: add 'store' param

This param allows you to opt a completion request in to being stored,
for use in distillations and evals.

* Add cached and audio tokens to usage structs

These have been added to the completions API recently:
https://platform.openai.com/docs/api-reference/chat/object#chat/object-usage
@pigri pigri merged commit a9f7f6c into openshieldai:master Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants