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

Side by Side Diff: components/dom_distiller/core/experiments.cc

Issue 1051673002: Add flags and experiment config for selecting triggering heuristics (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@dd-heuristics-apply
Patch Set: Created 5 years, 8 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 unified diff | Download patch
« no previous file with comments | « components/dom_distiller/core/experiments.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "components/dom_distiller/core/experiments.h"
6
7 #include "base/metrics/field_trial.h"
8
9 namespace dom_distiller {
10 DistillerHeuristicsType GetDistillerHeuristicsType() {
nyquist 2015/04/01 18:17:01 Should this check the flags as well? Or is that so
cjhopman 2015/04/01 19:22:54 That's implicit field trial magic. Adding the flag
cjhopman 2015/04/01 21:06:20 I've added explicitly checking the flags though wh
11 const std::string group_name =
12 base::FieldTrialList::FindFullName("ReaderModeUI");
13 if (group_name == "OGArticle" || group_name == "ForcedOGArticle") {
14 return DistillerHeuristicsType::OG_ARTICLE;
15 } else if (group_name == "AdaBoost" || group_name == "ForcedAdaBoost") {
16 return DistillerHeuristicsType::ADABOOST_MODEL;
17 }
18 return DistillerHeuristicsType::NONE;
19 }
20 }
OLDNEW
« no previous file with comments | « components/dom_distiller/core/experiments.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698