Class Content (1.48.0)

Content(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The base structured datatype containing multi-part content of a message.

A Content includes a role field designating the producer of the Content and a parts field containing multi-part data that contains the content of the message turn.

Attributes

NameDescription
role str
Optional. The producer of the content. Must be either 'user' or 'model'. Useful to set for multi-turn conversations, otherwise can be left blank or unset.
parts MutableSequence[google.cloud.aiplatform_v1beta1.types.Part]
Required. Ordered Parts that constitute a single message. Parts may have different IANA MIME types.

Methods

Content

Content(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The base structured datatype containing multi-part content of a message.

A Content includes a role field designating the producer of the Content and a parts field containing multi-part data that contains the content of the message turn.