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

Unified Diff: components/omnibox/browser/omnibox_field_trial.h

Issue 1411543011: Omnibox: Make Keyword Provide More Generous with Matching (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: == -> >= Created 5 years, 1 month 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
Index: components/omnibox/browser/omnibox_field_trial.h
diff --git a/components/omnibox/browser/omnibox_field_trial.h b/components/omnibox/browser/omnibox_field_trial.h
index b6e354993d5d8c59383ce63ebb299987de581cb9..8e94ea2b2739ab4eea291382bd8517d652237053 100644
--- a/components/omnibox/browser/omnibox_field_trial.h
+++ b/components/omnibox/browser/omnibox_field_trial.h
@@ -320,6 +320,29 @@ class OmniboxFieldTrial {
static bool PreventUWYTDefaultForNonURLInputs();
// ---------------------------------------------------------
+ // For the aggressive keyword matching experiment that's part of the bundled
+ // omnibox field trial.
+
+ // Return true if KeywordProvider (via TemplateURLService), for auto-
Peter Kasting 2015/11/09 23:11:14 Nit: Return -> Returns
Mark P 2015/11/11 07:41:00 Done.
+ // generated keywords, should consider the registry (e.g., co.uk) an
+ // important part of the keyword name for matching purposes. Returns true
Peter Kasting 2015/11/09 23:11:15 Nit: Awkward, how about: Returns whether the Keyw
Mark P 2015/11/11 07:41:00 This isn't correct. It can match against them eve
+ // if the experiment isn't active.
+ static bool KeywordRequiresRegistry();
+
+ // Return true if KeywordProvider (via TemplateURLService), for auto-
Peter Kasting 2015/11/09 23:11:14 Nit: Return -> Returns
Mark P 2015/11/11 07:41:00 Done.
+ // generated keywords, should return a keyword if the user starts typing
+ // the domain name portion, skipping any host before the domain name.
+ // In other words, returns whether the prefix before the domain name should
+ // be considered important for matching purposes. Returns true if the
Peter Kasting 2015/11/09 23:11:14 Nit: Awkward, how about: For autogenerated keywor
Mark P 2015/11/11 07:41:00 Revised somewhat in the direction you suggested.
+ // experiment isn't active.
+ static bool KeywordRequiresPrefixBeforeDomain();
+
+ // For the relevance score that KeywordProvider should assign to keywords
Peter Kasting 2015/11/09 23:11:15 Nit: For -> Returns
Mark P 2015/11/11 07:41:00 Done.
+ // with nearly-complete matches, i.e., the user has typed all of the
+ // important part of the keyword. Returns -1 if the experiment isn't active.
+ static int KeywordScoreForNearlyCompleteMatch();
+
+ // ---------------------------------------------------------
// Exposed publicly for the sake of unittests.
static const char kBundledExperimentFieldTrialName[];
// Rule names used by the bundled experiment.
@@ -341,6 +364,9 @@ class OmniboxFieldTrial {
static const char kHQPNumTitleWordsRule[];
static const char kHQPAlsoDoHUPLikeScoringRule[];
static const char kPreventUWYTDefaultForNonURLInputsRule[];
+ static const char kKeywordRequiresRegistryRule[];
+ static const char kKeywordRequiresPrefixBeforeDomainRule[];
+ static const char kKeywordScoreForNearlyCompleteMatchRule[];
// Parameter names used by the HUP new scoring experiments.
static const char kHUPNewScoringEnabledParam[];

Powered by Google App Engine
This is Rietveld 408576698