View Source LlmComposer.LlmResponse (llm_composer v0.8.0)
Module to parse and easily handle llm responses.
Summary
Types
@type model_response() :: Tesla.Env.result()
@type t() :: %LlmComposer.LlmResponse{ actions: [[LlmComposer.FunctionCall.t()]] | [LlmComposer.FunctionCall.t()], input_tokens: pos_integer() | nil, main_response: LlmComposer.Message.t() | nil, metadata: map(), output_tokens: pos_integer() | nil, previous_response: map() | nil, raw: map(), status: :ok | :error, stream: nil | Enum.t() }
Functions
@spec new(nil | model_response(), atom()) :: {:ok, t()} | {:error, term()}