Skip to content

Latest commit

 

History

History
84 lines (52 loc) · 1.71 KB

File metadata and controls

84 lines (52 loc) · 1.71 KB

google.generativeai.protos.GenerateTextResponse

View source on GitHub

The response from the model, including candidate completions.

Attributes

candidates

MutableSequence[google.ai.generativelanguage.TextCompletion]

Candidate responses from the model.

filters

MutableSequence[google.ai.generativelanguage.ContentFilter]

A set of content filtering metadata for the prompt and response text.

This indicates which SafetyCategory\ (s) blocked a candidate from this response, the lowest HarmProbability that triggered a block, and the HarmThreshold setting for that category. This indicates the smallest change to the SafetySettings that would be necessary to unblock at least 1 response.

The blocking is configured by the SafetySettings in the request (or the default SafetySettings of the API).

safety_feedback

MutableSequence[google.ai.generativelanguage.SafetyFeedback]

Returns any safety feedback related to content filtering.