generate Content Stream
Generates content with streaming support given a GenAI model and a list of content.
Unless GenerateContentConfig.automaticContinuation is false, a response that ends with finish reason CONTINUATION is continued: the same request is sent again with the response's continuation token until the model finishes, and the chunks of every request are emitted in order, with usage metadata accumulated across requests.
Return
a GenerateContentResponse instance that contains response contents and other metadata
Parameters
the name of the GenAI model to use for generation
a list of Content to send to the generative model
a GenerateContentConfig instance that specifies the optional configurations
Generates content with streaming support given a GenAI model and a content object.
Automatic continuation works as described on the overload taking a list of content.
Return
a GenerateContentResponse instance that contains response contents and other metadata
Parameters
the name of the GenAI model to use for generation
a Content to send to the generative model
a GenerateContentConfig instance that specifies the optional configurations
Generates content with streaming support given a GenAI model and a text string.
Automatic continuation works as described on the overload taking a list of content.
Return
a GenerateContentResponse instance that contains response contents and other metadata
Parameters
the name of the GenAI model to use for generation
the text string to send to the generative model
a GenerateContentConfig instance that specifies the optional configurations