Chromium Code Reviews| 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 2e4421d7b5a3c642a79ade2de6c777f617f8c103..090bd4d25b41b864f06ee07135d148b33d2e0f28 100644 |
| --- a/components/omnibox/browser/omnibox_field_trial.h |
| +++ b/components/omnibox/browser/omnibox_field_trial.h |
| @@ -44,6 +44,11 @@ struct HUPScoringParams { |
| half_life_days_ = half_life_days; |
| } |
| + bool use_decay_factor() const { return use_decay_factor_; } |
| + void set_use_decay_factor(bool use_decay_factor) { |
| + use_decay_factor_ = use_decay_factor; |
| + } |
| + |
| std::vector<CountMaxRelevance>& buckets() { return buckets_; } |
| const std::vector<CountMaxRelevance>& buckets() const { return buckets_; } |
| @@ -70,11 +75,16 @@ struct HUPScoringParams { |
| // |
| // This list is sorted by the pair's first element in descending order. |
| std::vector<CountMaxRelevance> buckets_; |
| + |
| + // Specify decay factor in buckets rather than actual score. |
| + bool use_decay_factor_ = false; |
|
Bart N.
2015/08/26 23:01:25
= false will most likely not compile on some platf
Ashok vardhan
2015/08/27 00:30:46
Done.
|
| }; |
| - HUPScoringParams() : experimental_scoring_enabled(false) {} |
| + HUPScoringParams() : experimental_scoring_enabled(false), |
| + default_scoring_enabled(false) {} |
| bool experimental_scoring_enabled; |
| + bool default_scoring_enabled; |
| ScoreBuckets typed_count_buckets; |
| @@ -210,6 +220,7 @@ class OmniboxFieldTrial { |
| // Initializes the HUP |scoring_params| based on the active HUP scoring |
| // experiment. If there is no such experiment, this function simply sets |
| // |scoring_params|->experimental_scoring_enabled to false. |
| + static void GetDefaultHUPScoringParams(HUPScoringParams* scoring_params); |
| static void GetExperimentalHUPScoringParams(HUPScoringParams* scoring_params); |
| // For the HQPBookmarkValue experiment that's part of the |
| @@ -338,9 +349,11 @@ class OmniboxFieldTrial { |
| static const char kHUPNewScoringTypedCountRelevanceCapParam[]; |
| static const char kHUPNewScoringTypedCountHalfLifeTimeParam[]; |
| static const char kHUPNewScoringTypedCountScoreBucketsParam[]; |
| + static const char kHUPNewScoringTypedCountUseDecayFactorParam[]; |
| static const char kHUPNewScoringVisitedCountRelevanceCapParam[]; |
| static const char kHUPNewScoringVisitedCountHalfLifeTimeParam[]; |
| static const char kHUPNewScoringVisitedCountScoreBucketsParam[]; |
| + static const char kHUPNewScoringVisitedCountUseDecayFactorParam[]; |
| // Parameter names used by the HQP experimental scoring experiments. |
| static const char kHQPExperimentalScoringEnabledParam[]; |