Skip to content

refactor: Make rust-sdk OpenAI Compatible #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

Merged
merged 23 commits into from
Mar 21, 2025
Merged

Conversation

edenreich
Copy link
Collaborator

@edenreich edenreich commented Mar 20, 2025

Summary

This Pull-Request bringing the rust-sdk to be OpenAI Compatible - just the internal endpoints and the data structures not the function names - these will stay without any change because there is no official rust-sdk for OpenAI yet.

BREAKING CHANGE: if you're running clients that using OpenAI sdks there are not much breaking changes in term of data structure, but if you used this library for a while, the changes are now moved in favor to support OpenAI data structure. I've went with this decision because many other tools are more standardized towards OpenAI, which making the transition seamlessly.

I will probably implement Google very soon, because I found out they have an OpenAI compatible API.

Signed-off-by: Eden Reich <[email protected]>
Otherwise it's conflicting with the trait Default that could be implemented. This approach seems more readable to me so I'll go with this approach.

Signed-off-by: Eden Reich <[email protected]>
## [0.9.1-rc.1](0.9.0...0.9.1-rc.1) (2025-03-20)

### ♻️ Improvements

* Add streaming response structures for chat completion ([0dd7b56](0dd7b56))
* Download the OpenAPI spec ([7701059](7701059))
* Remove Google provider from the Provider enum ([5a98051](5a98051))
* Remove nullable fields from OpenAPI schema definitions ([461750f](461750f))
* Rename default client method to new_default for clarity ([8735999](8735999))
* Rename GenerateRequest to CreateChatCompletionRequest and remove ssevents field ([52c4008](52c4008))
* Restructure response to be compatible with OpenAI ([88da800](88da800))
* Start by implementing default and base_url ([1afdaac](1afdaac))
* Update JSON response format to include new fields for chat completion ([38869a1](38869a1))
* Update JSON response structure with new fields for chat completion ([340c02c](340c02c))
* Update tool call structures for chat completion and enhance argument parsing ([c867978](c867978))

### 🐛 Bug Fixes

* Add output logging for version determination error in release workflow ([d49ba50](d49ba50))
Copy link

🎉 This PR is included in version 0.9.1-rc.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

## [0.9.1-rc.2](0.9.1-rc.1...0.9.1-rc.2) (2025-03-21)

### ♻️ Improvements

* Update model response structures for clarity and consistency ([5ca2eb5](5ca2eb5))

### 🔧 Miscellaneous

* Update dependencies for improved performance and security ([6079995](6079995))
Copy link

🎉 This PR is included in version 0.9.1-rc.2 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

## [0.9.1-rc.3](0.9.1-rc.2...0.9.1-rc.3) (2025-03-21)

### ♻️ Improvements

* Update API endpoints and logging for model listing ([96fec11](96fec11))
Copy link

🎉 This PR is included in version 0.9.1-rc.3 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Include the metrics of the streamed response in the example.

Signed-off-by: Eden Reich <[email protected]>
…use ChatCompletionMessageToolCallFunction

Signed-off-by: Eden Reich <[email protected]>
## [0.9.1-rc.4](0.9.1-rc.3...0.9.1-rc.4) (2025-03-21)

### ♻️ Improvements

* Remove ToolFunctionResponse and update ToolCallResponse to use ChatCompletionMessageToolCallFunction ([e3d29bb](e3d29bb))

### 📚 Documentation

* Enhance README with updated response types and improved logging ([651720b](651720b))
Copy link

🎉 This PR is included in version 0.9.1-rc.4 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

## [0.9.1-rc.5](0.9.1-rc.4...0.9.1-rc.5) (2025-03-21)

### ♻️ Improvements

* Improve example for Tool-Use ([bc647da](bc647da))
Copy link

🎉 This PR is included in version 0.9.1-rc.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@edenreich edenreich merged commit 08f92dc into main Mar 21, 2025
github-actions bot pushed a commit that referenced this pull request Mar 21, 2025
## [0.9.1](0.9.0...0.9.1) (2025-03-21)

### ♻️ Improvements

* Make rust-sdk OpenAI Compatible ([#8](#8)) ([08f92dc](08f92dc))
Copy link

🎉 This PR is included in version 0.9.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@edenreich edenreich deleted the rc/refactor-endpoints branch March 21, 2025 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant