Remove redundant case
This commit is contained in:
+1
-4
@@ -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()}
|
||||||
|
|||||||
Reference in New Issue
Block a user