1- // Copyright 2025 Google LLC
1+ // Copyright 2026 Google LLC
22//
33// Licensed under the Apache License, Version 2.0 (the "License");
44// you may not use this file except in compliance with the License.
@@ -964,6 +964,38 @@ message GenerateVideoResponse {
964964// Request message for
965965// [PredictionService.EmbedContent][google.cloud.aiplatform.v1beta1.PredictionService.EmbedContent].
966966message EmbedContentRequest {
967+ // Configurations for the EmbedContent API.
968+ message EmbedContentConfig {
969+ // Optional. The title for the text.
970+ //
971+ // Only applicable to text-only embedding models.
972+ optional string title = 1 [(google.api.field_behavior ) = OPTIONAL ];
973+
974+ // Optional. The task type of the embedding.
975+ //
976+ // Only applicable to text-only embedding models.
977+ optional EmbeddingTaskType task_type = 2
978+ [(google.api.field_behavior ) = OPTIONAL ];
979+
980+ // Optional. Whether to silently truncate the input content if it's longer
981+ // than the maximum sequence length.
982+ //
983+ // Only applicable to text-only embedding models.
984+ optional bool auto_truncate = 3 [(google.api.field_behavior ) = OPTIONAL ];
985+
986+ // Optional. Reduced dimension for the output embedding. If set, excessive
987+ // values in the output embedding are truncated from the end.
988+ optional int32 output_dimensionality = 4
989+ [(google.api.field_behavior ) = OPTIONAL ];
990+
991+ // Optional. Whether to enable OCR for document content.
992+ optional bool document_ocr = 5 [(google.api.field_behavior ) = OPTIONAL ];
993+
994+ // Optional. Whether to extract audio from video content.
995+ optional bool audio_track_extraction = 6
996+ [(google.api.field_behavior ) = OPTIONAL ];
997+ }
998+
967999 // Represents a downstream task the embeddings will be used for.
9681000 enum EmbeddingTaskType {
9691001 // Unset value, which will default to one of the other enum values.
@@ -1001,24 +1033,34 @@ message EmbedContentRequest {
10011033 type : "aiplatform.googleapis.com/Endpoint"
10021034 }];
10031035
1004- // Required. Input content to be embedded. Required.
1036+ // Required. Input content to be embedded.
10051037 optional Content content = 2 ;
10061038
1007- // Optional. An optional title for the text.
1008- optional string title = 4 [(google.api.field_behavior ) = OPTIONAL ];
1039+ // Optional. Deprecated: Please use EmbedContentConfig.title instead.
1040+ // The title for the text.
1041+ optional string title = 4
1042+ [deprecated = true , (google.api.field_behavior ) = OPTIONAL ];
10091043
1010- // Optional. The task type of the embedding.
1044+ // Optional. Deprecated: Please use EmbedContentConfig.task_type instead.
1045+ // The task type of the embedding.
10111046 optional EmbeddingTaskType task_type = 5
1012- [(google.api.field_behavior ) = OPTIONAL ];
1047+ [deprecated = true , (google.api.field_behavior ) = OPTIONAL ];
10131048
1014- // Optional. Optional reduced dimension for the output embedding. If set,
1015- // excessive values in the output embedding are truncated from the end.
1049+ // Optional. Deprecated: Please use EmbedContentConfig.output_dimensionality
1050+ // instead. Reduced dimension for the output embedding. If set, excessive
1051+ // values in the output embedding are truncated from the end.
10161052 optional int32 output_dimensionality = 6
1017- [(google.api.field_behavior ) = OPTIONAL ];
1053+ [deprecated = true , (google.api.field_behavior ) = OPTIONAL ];
10181054
1019- // Optional. Whether to silently truncate the input content if it's longer
1055+ // Optional. Deprecated: Please use EmbedContentConfig.auto_truncate instead.
1056+ // Whether to silently truncate the input content if it's longer
10201057 // than the maximum sequence length.
1021- optional bool auto_truncate = 7 [(google.api.field_behavior ) = OPTIONAL ];
1058+ optional bool auto_truncate = 7
1059+ [deprecated = true , (google.api.field_behavior ) = OPTIONAL ];
1060+
1061+ // Optional. Configuration for the EmbedContent request.
1062+ optional EmbedContentConfig embed_content_config = 8
1063+ [(google.api.field_behavior ) = OPTIONAL ];
10221064}
10231065
10241066// Response message for
@@ -1033,7 +1075,7 @@ message EmbedContentResponse {
10331075 // The embedding generated from the input content.
10341076 Embedding embedding = 1 ;
10351077
1036- // Metadata about the response(s).
1078+ // Usage metadata about the response(s).
10371079 UsageMetadata usage_metadata = 2 ;
10381080
10391081 // Whether the input content was truncated before generating the embedding.
0 commit comments