1*d5c09012SAndroid Build Coastguard Worker// Copyright 2020 Google LLC 2*d5c09012SAndroid Build Coastguard Worker// 3*d5c09012SAndroid Build Coastguard Worker// Licensed under the Apache License, Version 2.0 (the "License"); 4*d5c09012SAndroid Build Coastguard Worker// you may not use this file except in compliance with the License. 5*d5c09012SAndroid Build Coastguard Worker// You may obtain a copy of the License at 6*d5c09012SAndroid Build Coastguard Worker// 7*d5c09012SAndroid Build Coastguard Worker// http://www.apache.org/licenses/LICENSE-2.0 8*d5c09012SAndroid Build Coastguard Worker// 9*d5c09012SAndroid Build Coastguard Worker// Unless required by applicable law or agreed to in writing, software 10*d5c09012SAndroid Build Coastguard Worker// distributed under the License is distributed on an "AS IS" BASIS, 11*d5c09012SAndroid Build Coastguard Worker// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12*d5c09012SAndroid Build Coastguard Worker// See the License for the specific language governing permissions and 13*d5c09012SAndroid Build Coastguard Worker// limitations under the License. 14*d5c09012SAndroid Build Coastguard Worker 15*d5c09012SAndroid Build Coastguard Workersyntax = "proto3"; 16*d5c09012SAndroid Build Coastguard Worker 17*d5c09012SAndroid Build Coastguard Workerpackage google.cloud.dataqna.v1alpha; 18*d5c09012SAndroid Build Coastguard Worker 19*d5c09012SAndroid Build Coastguard Workerimport "google/api/field_behavior.proto"; 20*d5c09012SAndroid Build Coastguard Workerimport "google/api/resource.proto"; 21*d5c09012SAndroid Build Coastguard Workerimport "google/cloud/dataqna/v1alpha/annotated_string.proto"; 22*d5c09012SAndroid Build Coastguard Workerimport "google/protobuf/any.proto"; 23*d5c09012SAndroid Build Coastguard Workerimport "google/protobuf/timestamp.proto"; 24*d5c09012SAndroid Build Coastguard Workerimport "google/rpc/status.proto"; 25*d5c09012SAndroid Build Coastguard Worker 26*d5c09012SAndroid Build Coastguard Workeroption csharp_namespace = "Google.Cloud.DataQnA.V1Alpha"; 27*d5c09012SAndroid Build Coastguard Workeroption go_package = "cloud.google.com/go/dataqna/apiv1alpha/dataqnapb;dataqnapb"; 28*d5c09012SAndroid Build Coastguard Workeroption java_multiple_files = true; 29*d5c09012SAndroid Build Coastguard Workeroption java_outer_classname = "QuestionProto"; 30*d5c09012SAndroid Build Coastguard Workeroption java_package = "com.google.cloud.dataqna.v1alpha"; 31*d5c09012SAndroid Build Coastguard Workeroption php_namespace = "Google\\Cloud\\DataQnA\\V1alpha"; 32*d5c09012SAndroid Build Coastguard Workeroption ruby_package = "Google::Cloud::DataQnA::V1alpha"; 33*d5c09012SAndroid Build Coastguard Worker 34*d5c09012SAndroid Build Coastguard Worker// The question resource represents a natural language query, its settings, 35*d5c09012SAndroid Build Coastguard Worker// understanding generated by the system, and answer retrieval status. 36*d5c09012SAndroid Build Coastguard Worker// A question cannot be modified. 37*d5c09012SAndroid Build Coastguard Workermessage Question { 38*d5c09012SAndroid Build Coastguard Worker option (google.api.resource) = { 39*d5c09012SAndroid Build Coastguard Worker type: "dataqna.googleapis.com/Question" 40*d5c09012SAndroid Build Coastguard Worker pattern: "projects/{project}/locations/{location}/questions/{question}" 41*d5c09012SAndroid Build Coastguard Worker }; 42*d5c09012SAndroid Build Coastguard Worker 43*d5c09012SAndroid Build Coastguard Worker // Output only. Immutable. The unique identifier for the Question. The ID is server-generated. 44*d5c09012SAndroid Build Coastguard Worker // Example: `projects/foo/locations/bar/questions/123` 45*d5c09012SAndroid Build Coastguard Worker string name = 1 [ 46*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = OUTPUT_ONLY, 47*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = IMMUTABLE 48*d5c09012SAndroid Build Coastguard Worker ]; 49*d5c09012SAndroid Build Coastguard Worker 50*d5c09012SAndroid Build Coastguard Worker // Required. Immutable. Scopes to be used for the question. A scope defines the relevant data set 51*d5c09012SAndroid Build Coastguard Worker // scope. It can be a reference to a specific data source or a collection of 52*d5c09012SAndroid Build Coastguard Worker // data sources. Currently, support is limited to a single BigQuery table. 53*d5c09012SAndroid Build Coastguard Worker // There must be exactly one `scopes` element. 54*d5c09012SAndroid Build Coastguard Worker // 55*d5c09012SAndroid Build Coastguard Worker // Example: 56*d5c09012SAndroid Build Coastguard Worker // `//bigquery.googleapis.com/projects/test-project/datasets/foo/tables/bar` 57*d5c09012SAndroid Build Coastguard Worker repeated string scopes = 2 [ 58*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = REQUIRED, 59*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = IMMUTABLE 60*d5c09012SAndroid Build Coastguard Worker ]; 61*d5c09012SAndroid Build Coastguard Worker 62*d5c09012SAndroid Build Coastguard Worker // Required. Immutable. The query in natural language. 63*d5c09012SAndroid Build Coastguard Worker string query = 3 [ 64*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = REQUIRED, 65*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = IMMUTABLE 66*d5c09012SAndroid Build Coastguard Worker ]; 67*d5c09012SAndroid Build Coastguard Worker 68*d5c09012SAndroid Build Coastguard Worker // A list of annotations to use instead of the default annotation of a data 69*d5c09012SAndroid Build Coastguard Worker // source (set in the data source reference resource). There must not be 70*d5c09012SAndroid Build Coastguard Worker // more than one annotation with the same data source reference. 71*d5c09012SAndroid Build Coastguard Worker repeated string data_source_annotations = 4; 72*d5c09012SAndroid Build Coastguard Worker 73*d5c09012SAndroid Build Coastguard Worker // An error field explaining why interpretation failed. This is only populated 74*d5c09012SAndroid Build Coastguard Worker // if the interpretation failed. 75*d5c09012SAndroid Build Coastguard Worker // 76*d5c09012SAndroid Build Coastguard Worker // Note: This is different from getting a status error on the request itself. 77*d5c09012SAndroid Build Coastguard Worker // This is not a client or server error and the Question resource is still 78*d5c09012SAndroid Build Coastguard Worker // persisted, but the service could not interpret the question. Clients should 79*d5c09012SAndroid Build Coastguard Worker // present the error to the user so the user can rephrase the question. 80*d5c09012SAndroid Build Coastguard Worker InterpretError interpret_error = 5; 81*d5c09012SAndroid Build Coastguard Worker 82*d5c09012SAndroid Build Coastguard Worker // A list of interpretations for this question. 83*d5c09012SAndroid Build Coastguard Worker repeated Interpretation interpretations = 6; 84*d5c09012SAndroid Build Coastguard Worker 85*d5c09012SAndroid Build Coastguard Worker // Time when the question was created. 86*d5c09012SAndroid Build Coastguard Worker google.protobuf.Timestamp create_time = 7; 87*d5c09012SAndroid Build Coastguard Worker 88*d5c09012SAndroid Build Coastguard Worker // Output only. The e-mail address of the user that created this question. 89*d5c09012SAndroid Build Coastguard Worker string user_email = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; 90*d5c09012SAndroid Build Coastguard Worker 91*d5c09012SAndroid Build Coastguard Worker // Input only. Immutable. Flags to request additional information for debugging purposes. 92*d5c09012SAndroid Build Coastguard Worker DebugFlags debug_flags = 9 [ 93*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = IMMUTABLE, 94*d5c09012SAndroid Build Coastguard Worker (google.api.field_behavior) = INPUT_ONLY 95*d5c09012SAndroid Build Coastguard Worker ]; 96*d5c09012SAndroid Build Coastguard Worker 97*d5c09012SAndroid Build Coastguard Worker // Top level debug information. 98*d5c09012SAndroid Build Coastguard Worker // This will be stored as the type DebugInformation. 99*d5c09012SAndroid Build Coastguard Worker // Using Any so clients don't need to pull in anything 100*d5c09012SAndroid Build Coastguard Worker // inside the debug message. 101*d5c09012SAndroid Build Coastguard Worker google.protobuf.Any debug_info = 10; 102*d5c09012SAndroid Build Coastguard Worker} 103*d5c09012SAndroid Build Coastguard Worker 104*d5c09012SAndroid Build Coastguard Worker// Details on the failure to interpret the question. 105*d5c09012SAndroid Build Coastguard Workermessage InterpretError { 106*d5c09012SAndroid Build Coastguard Worker // Details on interpretation failure. 107*d5c09012SAndroid Build Coastguard Worker message InterpretErrorDetails { 108*d5c09012SAndroid Build Coastguard Worker // Populated if parts of the query are unsupported. 109*d5c09012SAndroid Build Coastguard Worker InterpretUnsupportedDetails unsupported_details = 1; 110*d5c09012SAndroid Build Coastguard Worker 111*d5c09012SAndroid Build Coastguard Worker // Populated if the query is incomplete. 112*d5c09012SAndroid Build Coastguard Worker InterpretIncompleteQueryDetails incomplete_query_details = 2; 113*d5c09012SAndroid Build Coastguard Worker 114*d5c09012SAndroid Build Coastguard Worker // Populated if the query was too ambiguous. 115*d5c09012SAndroid Build Coastguard Worker InterpretAmbiguityDetails ambiguity_details = 3; 116*d5c09012SAndroid Build Coastguard Worker } 117*d5c09012SAndroid Build Coastguard Worker 118*d5c09012SAndroid Build Coastguard Worker // Details about unsupported parts in a query. 119*d5c09012SAndroid Build Coastguard Worker message InterpretUnsupportedDetails { 120*d5c09012SAndroid Build Coastguard Worker // Unsupported operators. For example: median. 121*d5c09012SAndroid Build Coastguard Worker repeated string operators = 1; 122*d5c09012SAndroid Build Coastguard Worker 123*d5c09012SAndroid Build Coastguard Worker // Unsupported intents. 124*d5c09012SAndroid Build Coastguard Worker repeated string intent = 2; 125*d5c09012SAndroid Build Coastguard Worker } 126*d5c09012SAndroid Build Coastguard Worker 127*d5c09012SAndroid Build Coastguard Worker // Details about an incomplete query. 128*d5c09012SAndroid Build Coastguard Worker message InterpretIncompleteQueryDetails { 129*d5c09012SAndroid Build Coastguard Worker // List of missing interpret entities. 130*d5c09012SAndroid Build Coastguard Worker repeated InterpretEntity entities = 1; 131*d5c09012SAndroid Build Coastguard Worker } 132*d5c09012SAndroid Build Coastguard Worker 133*d5c09012SAndroid Build Coastguard Worker // Details about a query that was too ambiguous. Currently, the message 134*d5c09012SAndroid Build Coastguard Worker // has no fields and its presence signals that there was ambiguity. 135*d5c09012SAndroid Build Coastguard Worker message InterpretAmbiguityDetails { 136*d5c09012SAndroid Build Coastguard Worker 137*d5c09012SAndroid Build Coastguard Worker } 138*d5c09012SAndroid Build Coastguard Worker 139*d5c09012SAndroid Build Coastguard Worker // The interpret error code provides an error category why the interpretation 140*d5c09012SAndroid Build Coastguard Worker // failed. 141*d5c09012SAndroid Build Coastguard Worker enum InterpretErrorCode { 142*d5c09012SAndroid Build Coastguard Worker // No interpret error code was specified. 143*d5c09012SAndroid Build Coastguard Worker INTERPRET_ERROR_CODE_UNSPECIFIED = 0; 144*d5c09012SAndroid Build Coastguard Worker 145*d5c09012SAndroid Build Coastguard Worker // The query is not valid. 146*d5c09012SAndroid Build Coastguard Worker INVALID_QUERY = 1; 147*d5c09012SAndroid Build Coastguard Worker 148*d5c09012SAndroid Build Coastguard Worker // The interpreter failed to understand the question. For example, because 149*d5c09012SAndroid Build Coastguard Worker // it was too ambiguous. 150*d5c09012SAndroid Build Coastguard Worker FAILED_TO_UNDERSTAND = 2; 151*d5c09012SAndroid Build Coastguard Worker 152*d5c09012SAndroid Build Coastguard Worker // The interpreter could understand the question, but was not able to arrive 153*d5c09012SAndroid Build Coastguard Worker // at an answer. For example, because a requested operation is not 154*d5c09012SAndroid Build Coastguard Worker // supported. 155*d5c09012SAndroid Build Coastguard Worker FAILED_TO_ANSWER = 3; 156*d5c09012SAndroid Build Coastguard Worker } 157*d5c09012SAndroid Build Coastguard Worker 158*d5c09012SAndroid Build Coastguard Worker // Error message explaining why this question could not be interpreted. 159*d5c09012SAndroid Build Coastguard Worker string message = 1; 160*d5c09012SAndroid Build Coastguard Worker 161*d5c09012SAndroid Build Coastguard Worker // The code for the error category why the interpretation failed. 162*d5c09012SAndroid Build Coastguard Worker InterpretErrorCode code = 2; 163*d5c09012SAndroid Build Coastguard Worker 164*d5c09012SAndroid Build Coastguard Worker // Details on interpretation failure. 165*d5c09012SAndroid Build Coastguard Worker InterpretErrorDetails details = 3; 166*d5c09012SAndroid Build Coastguard Worker} 167*d5c09012SAndroid Build Coastguard Worker 168*d5c09012SAndroid Build Coastguard Worker// Information about the backend status (such as BigQuery) of the execution. 169*d5c09012SAndroid Build Coastguard Workermessage ExecutionInfo { 170*d5c09012SAndroid Build Coastguard Worker // Enum of possible job execution statuses. 171*d5c09012SAndroid Build Coastguard Worker enum JobExecutionState { 172*d5c09012SAndroid Build Coastguard Worker // No job execution was specified. 173*d5c09012SAndroid Build Coastguard Worker JOB_EXECUTION_STATE_UNSPECIFIED = 0; 174*d5c09012SAndroid Build Coastguard Worker 175*d5c09012SAndroid Build Coastguard Worker // No job execution was requested, yet. 176*d5c09012SAndroid Build Coastguard Worker NOT_EXECUTED = 1; 177*d5c09012SAndroid Build Coastguard Worker 178*d5c09012SAndroid Build Coastguard Worker // The job is running. 179*d5c09012SAndroid Build Coastguard Worker RUNNING = 2; 180*d5c09012SAndroid Build Coastguard Worker 181*d5c09012SAndroid Build Coastguard Worker // The job completed successfully. 182*d5c09012SAndroid Build Coastguard Worker SUCCEEDED = 3; 183*d5c09012SAndroid Build Coastguard Worker 184*d5c09012SAndroid Build Coastguard Worker // The job completed unsuccessfully. 185*d5c09012SAndroid Build Coastguard Worker FAILED = 4; 186*d5c09012SAndroid Build Coastguard Worker } 187*d5c09012SAndroid Build Coastguard Worker 188*d5c09012SAndroid Build Coastguard Worker // Status returned by the backend when the job was created. 189*d5c09012SAndroid Build Coastguard Worker google.rpc.Status job_creation_status = 1; 190*d5c09012SAndroid Build Coastguard Worker 191*d5c09012SAndroid Build Coastguard Worker // Status of the job execution. 192*d5c09012SAndroid Build Coastguard Worker JobExecutionState job_execution_state = 2; 193*d5c09012SAndroid Build Coastguard Worker 194*d5c09012SAndroid Build Coastguard Worker // Time when the execution was triggered. 195*d5c09012SAndroid Build Coastguard Worker google.protobuf.Timestamp create_time = 3; 196*d5c09012SAndroid Build Coastguard Worker 197*d5c09012SAndroid Build Coastguard Worker // BigQuery job information. 198*d5c09012SAndroid Build Coastguard Worker // Future versions will have different backends. Hence, clients must make sure 199*d5c09012SAndroid Build Coastguard Worker // they can handle it when this field is not populated. 200*d5c09012SAndroid Build Coastguard Worker BigQueryJob bigquery_job = 4; 201*d5c09012SAndroid Build Coastguard Worker} 202*d5c09012SAndroid Build Coastguard Worker 203*d5c09012SAndroid Build Coastguard Worker// BigQuery job information. This can be used to query the BigQuery API and 204*d5c09012SAndroid Build Coastguard Worker// retrieve the current job's status (using 205*d5c09012SAndroid Build Coastguard Worker// [jobs.get](https://cloud.google.com/bigquery/docs/reference/rest/v2/jobs/get)). 206*d5c09012SAndroid Build Coastguard Workermessage BigQueryJob { 207*d5c09012SAndroid Build Coastguard Worker // The job ID. 208*d5c09012SAndroid Build Coastguard Worker string job_id = 1; 209*d5c09012SAndroid Build Coastguard Worker 210*d5c09012SAndroid Build Coastguard Worker // The project ID of the job. 211*d5c09012SAndroid Build Coastguard Worker string project_id = 2; 212*d5c09012SAndroid Build Coastguard Worker 213*d5c09012SAndroid Build Coastguard Worker // The location where the job is running. 214*d5c09012SAndroid Build Coastguard Worker string location = 3; 215*d5c09012SAndroid Build Coastguard Worker} 216*d5c09012SAndroid Build Coastguard Worker 217*d5c09012SAndroid Build Coastguard Worker// An interpretation of a natural language query. 218*d5c09012SAndroid Build Coastguard Workermessage Interpretation { 219*d5c09012SAndroid Build Coastguard Worker // List of data sources used in the current understanding. 220*d5c09012SAndroid Build Coastguard Worker repeated string data_sources = 1; 221*d5c09012SAndroid Build Coastguard Worker 222*d5c09012SAndroid Build Coastguard Worker // The level of confidence that one of the interpretations is correct. This is 223*d5c09012SAndroid Build Coastguard Worker // a value in the range [0, 1] where a value of 0.5 or below is to be 224*d5c09012SAndroid Build Coastguard Worker // considered a low confidence. 225*d5c09012SAndroid Build Coastguard Worker double confidence = 2; 226*d5c09012SAndroid Build Coastguard Worker 227*d5c09012SAndroid Build Coastguard Worker // A list of unused phrases. Clients should display a Did You Mean (DYM) 228*d5c09012SAndroid Build Coastguard Worker // dialog if this is non-empty, even if this is the only interpretation. 229*d5c09012SAndroid Build Coastguard Worker repeated string unused_phrases = 3; 230*d5c09012SAndroid Build Coastguard Worker 231*d5c09012SAndroid Build Coastguard Worker // Human readable representation of the query. 232*d5c09012SAndroid Build Coastguard Worker HumanReadable human_readable = 4; 233*d5c09012SAndroid Build Coastguard Worker 234*d5c09012SAndroid Build Coastguard Worker // Information about the interpretation structure that helps to understand and 235*d5c09012SAndroid Build Coastguard Worker // visualize the response. 236*d5c09012SAndroid Build Coastguard Worker InterpretationStructure interpretation_structure = 5; 237*d5c09012SAndroid Build Coastguard Worker 238*d5c09012SAndroid Build Coastguard Worker // Representation of the data query to be sent to the backend. 239*d5c09012SAndroid Build Coastguard Worker DataQuery data_query = 6; 240*d5c09012SAndroid Build Coastguard Worker 241*d5c09012SAndroid Build Coastguard Worker // Information about the backend response. This is populated only if execution 242*d5c09012SAndroid Build Coastguard Worker // of an interpretation was requested. 243*d5c09012SAndroid Build Coastguard Worker ExecutionInfo execution_info = 7; 244*d5c09012SAndroid Build Coastguard Worker} 245*d5c09012SAndroid Build Coastguard Worker 246*d5c09012SAndroid Build Coastguard Worker// Representation of the data query for the backend. 247*d5c09012SAndroid Build Coastguard Worker// This is provided for informational purposes only. Clients should not use 248*d5c09012SAndroid Build Coastguard Worker// it to send it to the backend directly, but rather use the `execute` RPC 249*d5c09012SAndroid Build Coastguard Worker// to trigger the execution. Using the `execute` RPC is needed in order to 250*d5c09012SAndroid Build Coastguard Worker// track the state of a question and report on it correctly to the data 251*d5c09012SAndroid Build Coastguard Worker// administrators. 252*d5c09012SAndroid Build Coastguard Workermessage DataQuery { 253*d5c09012SAndroid Build Coastguard Worker // The generated SQL query to be sent to the backend. 254*d5c09012SAndroid Build Coastguard Worker string sql = 1; 255*d5c09012SAndroid Build Coastguard Worker} 256*d5c09012SAndroid Build Coastguard Worker 257*d5c09012SAndroid Build Coastguard Worker// Human readable interpretation. 258*d5c09012SAndroid Build Coastguard Workermessage HumanReadable { 259*d5c09012SAndroid Build Coastguard Worker // Generated query explaining the interpretation. 260*d5c09012SAndroid Build Coastguard Worker AnnotatedString generated_interpretation = 1; 261*d5c09012SAndroid Build Coastguard Worker 262*d5c09012SAndroid Build Coastguard Worker // Annotations on the original query. 263*d5c09012SAndroid Build Coastguard Worker AnnotatedString original_question = 2; 264*d5c09012SAndroid Build Coastguard Worker} 265*d5c09012SAndroid Build Coastguard Worker 266*d5c09012SAndroid Build Coastguard Worker// Information about the interpretation structure that helps to understand and 267*d5c09012SAndroid Build Coastguard Worker// visualize the response. 268*d5c09012SAndroid Build Coastguard Workermessage InterpretationStructure { 269*d5c09012SAndroid Build Coastguard Worker // Information about a column. 270*d5c09012SAndroid Build Coastguard Worker message ColumnInfo { 271*d5c09012SAndroid Build Coastguard Worker // The alias of the output column as used by the backend. For example, the 272*d5c09012SAndroid Build Coastguard Worker // field name in the schema provided in the query response in BigQuery. 273*d5c09012SAndroid Build Coastguard Worker string output_alias = 1; 274*d5c09012SAndroid Build Coastguard Worker 275*d5c09012SAndroid Build Coastguard Worker // Human readable name of the output column. 276*d5c09012SAndroid Build Coastguard Worker string display_name = 2; 277*d5c09012SAndroid Build Coastguard Worker } 278*d5c09012SAndroid Build Coastguard Worker 279*d5c09012SAndroid Build Coastguard Worker // Enumeration of visualzation types to use for query response data. 280*d5c09012SAndroid Build Coastguard Worker enum VisualizationType { 281*d5c09012SAndroid Build Coastguard Worker // No visualization type was specified. 282*d5c09012SAndroid Build Coastguard Worker VISUALIZATION_TYPE_UNSPECIFIED = 0; 283*d5c09012SAndroid Build Coastguard Worker 284*d5c09012SAndroid Build Coastguard Worker // Show a table. 285*d5c09012SAndroid Build Coastguard Worker TABLE = 1; 286*d5c09012SAndroid Build Coastguard Worker 287*d5c09012SAndroid Build Coastguard Worker // Show a [bar 288*d5c09012SAndroid Build Coastguard Worker // chart](https://developers.google.com/chart/interactive/docs/gallery/barchart). 289*d5c09012SAndroid Build Coastguard Worker BAR_CHART = 2; 290*d5c09012SAndroid Build Coastguard Worker 291*d5c09012SAndroid Build Coastguard Worker // Show a [column 292*d5c09012SAndroid Build Coastguard Worker // chart](https://developers.google.com/chart/interactive/docs/gallery/columnchart). 293*d5c09012SAndroid Build Coastguard Worker COLUMN_CHART = 3; 294*d5c09012SAndroid Build Coastguard Worker 295*d5c09012SAndroid Build Coastguard Worker // Show a 296*d5c09012SAndroid Build Coastguard Worker // [timeline](https://developers.google.com/chart/interactive/docs/gallery/timeline). 297*d5c09012SAndroid Build Coastguard Worker TIMELINE = 4; 298*d5c09012SAndroid Build Coastguard Worker 299*d5c09012SAndroid Build Coastguard Worker // Show a [scatter 300*d5c09012SAndroid Build Coastguard Worker // plot](https://developers.google.com/chart/interactive/docs/gallery/scatterchart). 301*d5c09012SAndroid Build Coastguard Worker SCATTER_PLOT = 5; 302*d5c09012SAndroid Build Coastguard Worker 303*d5c09012SAndroid Build Coastguard Worker // Show a [pie 304*d5c09012SAndroid Build Coastguard Worker // chart](https://developers.google.com/chart/interactive/docs/gallery/piechart). 305*d5c09012SAndroid Build Coastguard Worker PIE_CHART = 6; 306*d5c09012SAndroid Build Coastguard Worker 307*d5c09012SAndroid Build Coastguard Worker // Show a [line 308*d5c09012SAndroid Build Coastguard Worker // chart](https://developers.google.com/chart/interactive/docs/gallery/linechart). 309*d5c09012SAndroid Build Coastguard Worker LINE_CHART = 7; 310*d5c09012SAndroid Build Coastguard Worker 311*d5c09012SAndroid Build Coastguard Worker // Show an [area 312*d5c09012SAndroid Build Coastguard Worker // chart](https://developers.google.com/chart/interactive/docs/gallery/areachart). 313*d5c09012SAndroid Build Coastguard Worker AREA_CHART = 8; 314*d5c09012SAndroid Build Coastguard Worker 315*d5c09012SAndroid Build Coastguard Worker // Show a [combo 316*d5c09012SAndroid Build Coastguard Worker // chart](https://developers.google.com/chart/interactive/docs/gallery/combochart). 317*d5c09012SAndroid Build Coastguard Worker COMBO_CHART = 9; 318*d5c09012SAndroid Build Coastguard Worker 319*d5c09012SAndroid Build Coastguard Worker // Show a 320*d5c09012SAndroid Build Coastguard Worker // [histogram](https://developers.google.com/chart/interactive/docs/gallery/histogram). 321*d5c09012SAndroid Build Coastguard Worker HISTOGRAM = 10; 322*d5c09012SAndroid Build Coastguard Worker 323*d5c09012SAndroid Build Coastguard Worker // This denotes queries when the user has not specified the particular type 324*d5c09012SAndroid Build Coastguard Worker // of chart and has mentioned only a generic chart name such as "Chart", 325*d5c09012SAndroid Build Coastguard Worker // "Plot", "Graph", etc. This will differentiate it from specific charting 326*d5c09012SAndroid Build Coastguard Worker // terms such as "Bar chart", "Pie chart", etc. 327*d5c09012SAndroid Build Coastguard Worker GENERIC_CHART = 11; 328*d5c09012SAndroid Build Coastguard Worker 329*d5c09012SAndroid Build Coastguard Worker // The user tried to specify a chart type, but the interpreter could not 330*d5c09012SAndroid Build Coastguard Worker // understand the type. The client should display a generic chart and may 331*d5c09012SAndroid Build Coastguard Worker // give a hint to the user that the requested type was not understood. 332*d5c09012SAndroid Build Coastguard Worker CHART_NOT_UNDERSTOOD = 12; 333*d5c09012SAndroid Build Coastguard Worker } 334*d5c09012SAndroid Build Coastguard Worker 335*d5c09012SAndroid Build Coastguard Worker // List of possible visualization types to apply for this interpretation. The 336*d5c09012SAndroid Build Coastguard Worker // order has no relevance. 337*d5c09012SAndroid Build Coastguard Worker repeated VisualizationType visualization_types = 1; 338*d5c09012SAndroid Build Coastguard Worker 339*d5c09012SAndroid Build Coastguard Worker // Information about the output columns, that is, the columns that will be 340*d5c09012SAndroid Build Coastguard Worker // returned by the backend. 341*d5c09012SAndroid Build Coastguard Worker repeated ColumnInfo column_info = 2; 342*d5c09012SAndroid Build Coastguard Worker} 343*d5c09012SAndroid Build Coastguard Worker 344*d5c09012SAndroid Build Coastguard Worker// Configuriation of debug flags. 345*d5c09012SAndroid Build Coastguard Workermessage DebugFlags { 346*d5c09012SAndroid Build Coastguard Worker // Whether to include the original VAQuery. 347*d5c09012SAndroid Build Coastguard Worker bool include_va_query = 1; 348*d5c09012SAndroid Build Coastguard Worker 349*d5c09012SAndroid Build Coastguard Worker // Whether to include the original nested VAQuery. 350*d5c09012SAndroid Build Coastguard Worker bool include_nested_va_query = 2; 351*d5c09012SAndroid Build Coastguard Worker 352*d5c09012SAndroid Build Coastguard Worker // Whether to include the original human interpretation strings generated 353*d5c09012SAndroid Build Coastguard Worker // by Analyza. 354*d5c09012SAndroid Build Coastguard Worker bool include_human_interpretation = 3; 355*d5c09012SAndroid Build Coastguard Worker 356*d5c09012SAndroid Build Coastguard Worker // Whether to include the Aqua debug response. 357*d5c09012SAndroid Build Coastguard Worker bool include_aqua_debug_response = 4; 358*d5c09012SAndroid Build Coastguard Worker 359*d5c09012SAndroid Build Coastguard Worker // The time in milliseconds from Unix epoch to be used 360*d5c09012SAndroid Build Coastguard Worker // to process the query. This is useful for testing 361*d5c09012SAndroid Build Coastguard Worker // the queries at different time period. 362*d5c09012SAndroid Build Coastguard Worker // If not set or time_override <= 0, then the current 363*d5c09012SAndroid Build Coastguard Worker // time is used. 364*d5c09012SAndroid Build Coastguard Worker int64 time_override = 5; 365*d5c09012SAndroid Build Coastguard Worker 366*d5c09012SAndroid Build Coastguard Worker // Set to true if request is initiated by an internal Google user. 367*d5c09012SAndroid Build Coastguard Worker bool is_internal_google_user = 6; 368*d5c09012SAndroid Build Coastguard Worker 369*d5c09012SAndroid Build Coastguard Worker // Determines whether cache needs to be ignored. If set to 370*d5c09012SAndroid Build Coastguard Worker // true, cache won't be queried and updated. 371*d5c09012SAndroid Build Coastguard Worker bool ignore_cache = 7; 372*d5c09012SAndroid Build Coastguard Worker 373*d5c09012SAndroid Build Coastguard Worker // Whether to include the request/response pair from the call to the 374*d5c09012SAndroid Build Coastguard Worker // EntityIndex for SearchEntities. 375*d5c09012SAndroid Build Coastguard Worker bool include_search_entities_rpc = 8; 376*d5c09012SAndroid Build Coastguard Worker 377*d5c09012SAndroid Build Coastguard Worker // Whether to include the request/response pair from the call to the 378*d5c09012SAndroid Build Coastguard Worker // Annotations service for ListColumnAnnotations. 379*d5c09012SAndroid Build Coastguard Worker bool include_list_column_annotations_rpc = 9; 380*d5c09012SAndroid Build Coastguard Worker 381*d5c09012SAndroid Build Coastguard Worker // Whether to include the entity list passed to Analyza. 382*d5c09012SAndroid Build Coastguard Worker bool include_virtual_analyst_entities = 10; 383*d5c09012SAndroid Build Coastguard Worker 384*d5c09012SAndroid Build Coastguard Worker // Whether to include the table list. 385*d5c09012SAndroid Build Coastguard Worker bool include_table_list = 11; 386*d5c09012SAndroid Build Coastguard Worker 387*d5c09012SAndroid Build Coastguard Worker // Whether to include the domain list. 388*d5c09012SAndroid Build Coastguard Worker bool include_domain_list = 12; 389*d5c09012SAndroid Build Coastguard Worker} 390*d5c09012SAndroid Build Coastguard Worker 391*d5c09012SAndroid Build Coastguard Worker// Query entities of an interpretation. 392*d5c09012SAndroid Build Coastguard Workerenum InterpretEntity { 393*d5c09012SAndroid Build Coastguard Worker // No interpret entity was specified. 394*d5c09012SAndroid Build Coastguard Worker INTERPRET_ENTITY_UNSPECIFIED = 0; 395*d5c09012SAndroid Build Coastguard Worker 396*d5c09012SAndroid Build Coastguard Worker // A dimenstion entity. 397*d5c09012SAndroid Build Coastguard Worker DIMENSION = 1; 398*d5c09012SAndroid Build Coastguard Worker 399*d5c09012SAndroid Build Coastguard Worker // A metric entity. 400*d5c09012SAndroid Build Coastguard Worker METRIC = 2; 401*d5c09012SAndroid Build Coastguard Worker} 402