Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(511)

Unified Diff: components/sync/protocol/user_event_specifics.proto

Issue 2892553003: Initial proto for language detection. (Closed)
Patch Set: fix Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/sync/protocol/proto_visitors.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/sync/protocol/user_event_specifics.proto
diff --git a/components/sync/protocol/user_event_specifics.proto b/components/sync/protocol/user_event_specifics.proto
index fa74e61191c68b9baa92b54ece3a38c978069253..d02b2833eb7ca9db5b8859bb587a5b799e961b5b 100644
--- a/components/sync/protocol/user_event_specifics.proto
+++ b/components/sync/protocol/user_event_specifics.proto
@@ -21,6 +21,24 @@ message FieldTrialEvent {
repeated FieldTrial field_trials = 1;
}
+// Language detection output.
+message LanguageDetection {
+ message Language {
+ // ISO 639 language code will be used.
+ optional string language_code = 1;
+ // Whether the detected language is reliable, note this is determined by
+ // the CLD3.
+ optional bool is_reliable = 2;
+ }
+ // Top n languages. Typically we just log the top language, but for page that
+ // we're not confident about, we may log up to 3 top languages in descending
+ // order.
+ repeated Language detected_languages = 1;
+ // Adopted language is the final determined language.
+ // It will be stored only if it's different from the first detected language.
+ optional string adopted_language = 2;
+}
+
message UserEventSpecifics {
// Time of event, as measured on the client (unix epoch).
optional int64 event_time_usec = 1;
@@ -32,5 +50,8 @@ message UserEventSpecifics {
// other events belonged to.
optional fixed64 session_id = 3;
- oneof event { FieldTrialEvent field_trial_event = 4; }
+ oneof event {
+ FieldTrialEvent field_trial_event = 4;
+ LanguageDetection language_detection = 5;
+ }
}
« no previous file with comments | « components/sync/protocol/proto_visitors.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698