Reference documentation and code samples for the Vertex AI V1 API class Google::Cloud::AIPlatform::V1::GenerateContentResponse.
Response message for [PredictionService.GenerateContent].
Inherits
- Object
Extended By
- Google::Protobuf::MessageExts::ClassMethods
Includes
- Google::Protobuf::MessageExts
Methods
#candidates
def candidates() -> ::Array<::Google::Cloud::AIPlatform::V1::Candidate>
Returns
- (::Array<::Google::Cloud::AIPlatform::V1::Candidate>) — Output only. Generated candidates.
#create_time
def create_time() -> ::Google::Protobuf::Timestamp
Returns
- (::Google::Protobuf::Timestamp) — Output only. Timestamp when the request is made to the server.
#model_version
def model_version() -> ::String
Returns
- (::String) — Output only. The model version used to generate the response.
#prompt_feedback
def prompt_feedback() -> ::Google::Cloud::AIPlatform::V1::GenerateContentResponse::PromptFeedback
Returns
- (::Google::Cloud::AIPlatform::V1::GenerateContentResponse::PromptFeedback) — Output only. Content filter results for a prompt sent in the request. Note: Sent only in the first stream chunk. Only happens when no candidates were generated due to content violations.
#response_id
def response_id() -> ::String
Returns
- (::String) — Output only. response_id is used to identify each response. It is the encoding of the event_id.
#usage_metadata
def usage_metadata() -> ::Google::Cloud::AIPlatform::V1::GenerateContentResponse::UsageMetadata
Returns
- (::Google::Cloud::AIPlatform::V1::GenerateContentResponse::UsageMetadata) — Usage metadata about the response(s).
#usage_metadata=
def usage_metadata=(value) -> ::Google::Cloud::AIPlatform::V1::GenerateContentResponse::UsageMetadata
Parameter
- value (::Google::Cloud::AIPlatform::V1::GenerateContentResponse::UsageMetadata) — Usage metadata about the response(s).
Returns
- (::Google::Cloud::AIPlatform::V1::GenerateContentResponse::UsageMetadata) — Usage metadata about the response(s).