1// Copyright 2022 Google LLC 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15syntax = "proto3"; 16 17package google.cloud.discoveryengine.v1; 18 19import "google/api/resource.proto"; 20 21option csharp_namespace = "Google.Cloud.DiscoveryEngine.V1"; 22option go_package = "cloud.google.com/go/discoveryengine/apiv1/discoveryenginepb;discoveryenginepb"; 23option java_multiple_files = true; 24option java_outer_classname = "CommonProto"; 25option java_package = "com.google.cloud.discoveryengine.v1"; 26option objc_class_prefix = "DISCOVERYENGINE"; 27option php_namespace = "Google\\Cloud\\DiscoveryEngine\\V1"; 28option ruby_package = "Google::Cloud::DiscoveryEngine::V1"; 29option (google.api.resource_definition) = { 30 type: "discoveryengine.googleapis.com/Branch" 31 pattern: "projects/{project}/locations/{location}/dataStores/{data_store}/branches/{branch}" 32 pattern: "projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/branches/{branch}" 33}; 34option (google.api.resource_definition) = { 35 type: "discoveryengine.googleapis.com/Collection" 36 pattern: "projects/{project}/locations/{location}/collections/{collection}" 37}; 38option (google.api.resource_definition) = { 39 type: "discoveryengine.googleapis.com/ServingConfig" 40 pattern: "projects/{project}/locations/{location}/dataStores/{data_store}/servingConfigs/{serving_config}" 41 pattern: "projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/servingConfigs/{serving_config}" 42 pattern: "projects/{project}/locations/{location}/collections/{collection}/engines/{engine}/servingConfigs/{serving_config}" 43}; 44option (google.api.resource_definition) = { 45 type: "healthcare.googleapis.com/FhirStore" 46 pattern: "projects/{project}/locations/{location}/datasets/{dataset}/fhirStores/{fhir_store}" 47}; 48 49// The industry vertical associated with the 50// [DataStore][google.cloud.discoveryengine.v1.DataStore]. 51enum IndustryVertical { 52 // Value used when unset. 53 INDUSTRY_VERTICAL_UNSPECIFIED = 0; 54 55 // The generic vertical for documents that are not specific to any industry 56 // vertical. 57 GENERIC = 1; 58 59 // The media industry vertical. 60 MEDIA = 2; 61 62 // The healthcare FHIR vertical. 63 HEALTHCARE_FHIR = 7; 64} 65 66// The type of solution. 67enum SolutionType { 68 // Default value. 69 SOLUTION_TYPE_UNSPECIFIED = 0; 70 71 // Used for Recommendations AI. 72 SOLUTION_TYPE_RECOMMENDATION = 1; 73 74 // Used for Discovery Search. 75 SOLUTION_TYPE_SEARCH = 2; 76 77 // Used for use cases related to the Generative AI agent. 78 SOLUTION_TYPE_CHAT = 3; 79 80 // Used for use cases related to the Generative Chat agent. 81 // It's used for Generative chat engine only, the associated data stores 82 // must enrolled with `SOLUTION_TYPE_CHAT` solution. 83 SOLUTION_TYPE_GENERATIVE_CHAT = 4; 84} 85 86// Tiers of search features. Different tiers might have different 87// pricing. To learn more, check the pricing documentation. 88enum SearchTier { 89 // Default value when the enum is unspecified. This is invalid to use. 90 SEARCH_TIER_UNSPECIFIED = 0; 91 92 // Standard tier. 93 SEARCH_TIER_STANDARD = 1; 94 95 // Enterprise tier. 96 SEARCH_TIER_ENTERPRISE = 2; 97} 98 99// Add-on that provides additional functionality for search. 100enum SearchAddOn { 101 // Default value when the enum is unspecified. This is invalid to use. 102 SEARCH_ADD_ON_UNSPECIFIED = 0; 103 104 // Large language model add-on. 105 SEARCH_ADD_ON_LLM = 1; 106} 107 108// A floating point interval. 109message Interval { 110 // The lower bound of the interval. If neither of the min fields are 111 // set, then the lower bound is negative infinity. 112 // 113 // This field must be not larger than max. 114 // Otherwise, an `INVALID_ARGUMENT` error is returned. 115 oneof min { 116 // Inclusive lower bound. 117 double minimum = 1; 118 119 // Exclusive lower bound. 120 double exclusive_minimum = 2; 121 } 122 123 // The upper bound of the interval. If neither of the max fields are 124 // set, then the upper bound is positive infinity. 125 // 126 // This field must be not smaller than min. 127 // Otherwise, an `INVALID_ARGUMENT` error is returned. 128 oneof max { 129 // Inclusive upper bound. 130 double maximum = 3; 131 132 // Exclusive upper bound. 133 double exclusive_maximum = 4; 134 } 135} 136 137// A custom attribute that is not explicitly modeled in a resource, e.g. 138// [UserEvent][google.cloud.discoveryengine.v1.UserEvent]. 139message CustomAttribute { 140 // The textual values of this custom attribute. For example, `["yellow", 141 // "green"]` when the key is "color". 142 // 143 // Empty string is not allowed. Otherwise, an `INVALID_ARGUMENT` error is 144 // returned. 145 // 146 // Exactly one of 147 // [CustomAttribute.text][google.cloud.discoveryengine.v1.CustomAttribute.text] 148 // or 149 // [CustomAttribute.numbers][google.cloud.discoveryengine.v1.CustomAttribute.numbers] 150 // should be set. Otherwise, an `INVALID_ARGUMENT` error is returned. 151 repeated string text = 1; 152 153 // The numerical values of this custom attribute. For example, `[2.3, 15.4]` 154 // when the key is "lengths_cm". 155 // 156 // Exactly one of 157 // [CustomAttribute.text][google.cloud.discoveryengine.v1.CustomAttribute.text] 158 // or 159 // [CustomAttribute.numbers][google.cloud.discoveryengine.v1.CustomAttribute.numbers] 160 // should be set. Otherwise, an `INVALID_ARGUMENT` error is returned. 161 repeated double numbers = 2; 162} 163 164// Information of an end user. 165message UserInfo { 166 // Highly recommended for logged-in users. Unique identifier for logged-in 167 // user, such as a user name. Don't set for anonymous users. 168 // 169 // Always use a hashed value for this ID. 170 // 171 // Don't set the field to the same fixed ID for different users. This mixes 172 // the event history of those users together, which results in degraded 173 // model quality. 174 // 175 // The field must be a UTF-8 encoded string with a length limit of 128 176 // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. 177 string user_id = 1; 178 179 // User agent as included in the HTTP header. 180 // 181 // The field must be a UTF-8 encoded string with a length limit of 1,000 182 // characters. Otherwise, an `INVALID_ARGUMENT` error is returned. 183 // 184 // This should not be set when using the client side event reporting with 185 // GTM or JavaScript tag in 186 // [UserEventService.CollectUserEvent][google.cloud.discoveryengine.v1.UserEventService.CollectUserEvent] 187 // or if 188 // [UserEvent.direct_user_request][google.cloud.discoveryengine.v1.UserEvent.direct_user_request] 189 // is set. 190 string user_agent = 2; 191} 192