Remove redundant case

This commit is contained in:
Claudio Ortolina
2026-04-26 19:01:44 +01:00
parent 8e2a9b4941
commit d6e154b7b3
+1 -4
View File
@@ -24,10 +24,7 @@ defmodule OpenAI do
instructions = Keyword.get(opts, :instructions, "") instructions = Keyword.get(opts, :instructions, "")
on_chunk = Keyword.fetch!(opts, :on_chunk) on_chunk = Keyword.fetch!(opts, :on_chunk)
case API.chat_stream(messages, instructions, model, temperature, open_ai_config(), on_chunk) do API.chat_stream(messages, instructions, model, temperature, open_ai_config(), on_chunk)
:ok -> :ok
{:error, _reason} = error -> error
end
end end
@spec embeddings(String.t()) :: {:ok, [float()]} | {:error, term()} @spec embeddings(String.t()) :: {:ok, [float()]} | {:error, term()}