Ruby Openai Versions Save

OpenAI API + Ruby! 🤖❤️ Now with GPT4o 🚀🚀🚀

v5.2.0

7 months ago

Fix

v5.1.0

9 months ago

Added

  • Added rough_token_count to estimate tokens in a string according to OpenAI's "rules of thumb". Thank you to @jamiemccarthy for the idea and implementation!

v5.0.0

9 months ago

Added

  • Support multi-tenant use of the gem! Each client now holds its own config, so you can create unlimited clients in the same project, for example to Azure and OpenAI, or for different headers, access keys, etc.
  • [BREAKING-ish] This change should only break your usage of ruby-openai if you are directly calling class methods like OpenAI::Client.get for some reason, as they are now instance methods. Normal usage of the gem should be unaffected, just you can make new clients and they'll keep their own config if you want, overriding the global config.
  • Huge thanks to @petergoldstein for his original work on this, @cthulhu for testing and many others for reviews and suggestions.

Changed

  • [BREAKING] Move audio related method to Audio model from Client model. You will need to update your code to handle this change, changing client.translate to client.audio.translate and client.transcribe to client.audio.transcribe.

v4.3.2

9 months ago

Fixed

  • Don't overwrite config extra-headers when making a client without different ones. Thanks to @swistaczek for raising this!
  • Include extra-headers for Azure requests.

v4.3.1

9 months ago

Fixed

  • Tempfiles can now be sent to the API as well as Files, eg for Whisper. Thanks to @codergeek121 for the fix!

v4.3.0

9 months ago

Added

  • Add extra-headers to config to allow setting openai-caching-proxy-worker TTL, Helicone Auth and anything else ya need. Ty to @deltaguita and @marckohlbrugge for the PR!

v4.2.0

11 months ago

Added

  • Add Azure OpenAI Service support. Thanks to @rmachielse and @steffansluis for the PR and to everyone who requested this feature!

v4.1.0

1 year ago

Added

  • Add the ability to trigger any callable object as stream chunks come through, not just Procs. Big thanks to @obie for this change.

v4.0.0

1 year ago

Added

  • Add the ability to stream Chat responses from the API! Thanks to everyone who requested this and made suggestions.
  • Added instructions for streaming to the README.

Changed

  • Switch HTTP library from HTTParty to Faraday to allow streaming and future feature and performance improvements.
  • [BREAKING] Endpoints now return JSON rather than HTTParty objects. You will need to update your code to handle this change, changing JSON.parse(response.body)["key"] and response.parsed_response["key"] to just response["key"].

v3.7.0

1 year ago

Added