| // Copyright 2024 The Chromium Authors |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| syntax = "proto3"; |
| |
| package optimization_guide.proto; |
| |
| import "components/optimization_guide/proto/features/common_quality_data.proto"; |
| |
| import "components/optimization_guide/proto/model_quality_metadata.proto"; |
| |
| option optimize_for = LITE_RUNTIME; |
| option java_package = "org.chromium.components.optimization_guide.features.proto"; |
| |
| option java_outer_classname = "FormsPredictionsProto"; |
| |
| // DO NOT EDIT THIS FILE DIRECTLY! |
| // |
| // This file is generated in g3 and then synced to Chrome. Instead, please |
| // refer to http://go/chrome-intelligence-feature-protos (Google-internal link), |
| // and then changes will be synced with Chrome automatically. |
| |
| // Next ID: 5 |
| message FormsPredictionsLoggingData { |
| FormsPredictionsRequest request = 1; |
| |
| FormsPredictionsResponse response = 2; |
| |
| FormsPredictionsQuality quality = 3; |
| |
| ModelExecutionInfo model_execution_info = 4; |
| } |
| |
| message FormsPredictionsRequest { |
| // The context of the page that the form is on. |
| PageContext page_context = 1; |
| |
| // The form to predict values for. It is expected for the values for each |
| // field to be empty. |
| FormData form_data = 4; |
| |
| // The current entries in the user annotations database helpful for filling |
| // out this form. |
| repeated UserAnnotationsEntry entries = 5; |
| } |
| |
| message FormsPredictionsResponse { |
| // The confidence of the prediction. Will be between 0 and 1, inclusive. |
| float confidence = 1; |
| |
| // The filled out form. |
| FilledFormData form_data = 2; |
| } |
| |
| message FilledFormData { |
| // The data for each field that was filled out. |
| repeated FilledFormFieldData filled_form_field_data = 1; |
| } |
| |
| message FilledFormFieldData { |
| // The field that was filled out. |
| FormFieldData field_data = 1; |
| |
| // The predicted values for the field, allowing multiple predictions. |
| repeated PredictedValue predicted_values = 2; |
| |
| // A user-friendly version of the field's label, suitable for display. |
| // If empty or not provided, the original field label should be used. |
| string normalized_label = 3; |
| |
| // The index of the field in the request form. |
| int32 request_field_index = 4; |
| } |
| |
| message PredictedValue { |
| string value = 1; |
| } |
| |
| message FormsPredictionsQuality { |
| UserFeedback user_feedback = 1; |
| } |