Geminix.V1beta.GenerateTextResponse (geminix v0.2.0)
The response from the model, including candidate completions.
Fields:
:candidates(list ofGeminix.V1beta.TextCompletion.t/0) - Candidate responses from the model.:filters(list ofGeminix.V1beta.ContentFilter.t/0) - A set of content filtering metadata for the prompt and response text. This indicates whichSafetyCategory(s) blocked a candidate from this response, the lowestHarmProbabilitythat triggered a block, and the HarmThreshold setting for that category. This indicates the smallest change to theSafetySettingsthat would be necessary to unblock at least 1 response. The blocking is configured by theSafetySettingsin the request (or the defaultSafetySettingsof the API).:safety_feedback(list ofGeminix.V1beta.SafetyFeedback.t/0) - Returns any safety feedback related to content filtering.
Summary
Functions
Create a Geminix.V1beta.GenerateTextResponse.t/0 from a map returned
by the Gemini API.
Types
@type t() :: %Geminix.V1beta.GenerateTextResponse{ __meta__: term(), candidates: [Geminix.V1beta.TextCompletion.t()], filters: [Geminix.V1beta.ContentFilter.t()], safety_feedback: [Geminix.V1beta.SafetyFeedback.t()] }
Functions
@spec from_map(t(), map()) :: {:ok, t()} | {:error, Ecto.Changeset.t()}
Create a Geminix.V1beta.GenerateTextResponse.t/0 from a map returned
by the Gemini API.
Sometimes, this function should not be applied to the full response body, but instead it should be applied to the correct part of the map in the response body. This depends on the concrete API call.