You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@alexrudall love your gem and the amazing work you've been doing here!, everything works amazingly, I'm having this small issue with Streams that I'm not sure if is related to something missing in the docs or the latest version code Super appreciate your help beforehand.
Describe the bug
Getting the following error when trying to use the stream argument
{"error"=>{"message"=>"{} is not of type 'boolean' - 'stream'", "type"=>"invalid_request_error", "param"=>nil, "code"=>nil}}
To Reproduce
Steps to reproduce the behavior:
I have the gem in the gemfile listed as gem "ruby-openai" in the Gemfile.lock list version ruby-openai (3.7.0)
Example code
client = OpenAI::Client.new(access_token: access_token, request_timeout: 360)
client.chat(
parameters: {
model: "gpt-4-0125-preview",
messages: [{ role: "user", content: "Describe a character called Anna!" }],
temperature: 0.7,
stream: proc do |chunk, _bytesize|
puts chunk
end
}
)
@alexrudall love your gem and the amazing work you've been doing here!, everything works amazingly, I'm having this small issue with Streams that I'm not sure if is related to something missing in the docs or the latest version code Super appreciate your help beforehand.
Describe the bug
Getting the following error when trying to use the stream argument
To Reproduce
Steps to reproduce the behavior:
gem "ruby-openai"
in the Gemfile.lock list versionruby-openai (3.7.0)
Getting similar behavior while following this example https://gist.github.com/alexrudall/cb5ee1e109353ef358adb4e66631799d
Expected behavior
Stream should return answers from OpenAI
Desktop (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: