docs: function Readability(doc, options) {
    // In some older versions, people passed a URI as the first argument. Cope:
    if (options && options.documentElement) {
      doc = options;
      options = arguments[2];
    } else if (!doc || !doc.documentElement) {
      throw new Error("First argument to Readability constructor should be a document object.");
    }
    options = options || {};
  
    this._doc = doc;
    this._articleTitle = null;
    this._articleByline = null;
    this._articleDir = null;
    this._attempts = [];
  
    // Configurable options
    this._debug = !!options.debug;
    this._maxElemsToParse = options.maxElemsToParse || this.DEFAULT_MAX_ELEMS_TO_PARSE;
    this._nbTopCandidates = options.nbTopCandidates || this.DEFAULT_N_TOP_CANDIDATES;
    this._charThreshold = options.charThreshold || this.DEFAULT_CHAR_THRESHOLD;
    this._classesToPreserve = this.CLASSES_TO_PRESERVE.concat(options.classesToPreserve || []);
  
    // Start with all flags set
    this._flags = this.FLAG_STRIP_UNLIKELYS |
                  this.FLAG_WEIGHT_CLASSES |
                  this.FLAG_CLEAN_CONDITIONALLY;
  
    var logEl;
  
    // Control whether log messages are sent to the console
    if (this._debug) {
      logEl = function(e) {
        var rv = e.nodeName + " ";
        if (e.nodeType == e.TEXT_NODE) {
          return rv + '("' + e.textContent + '")';
        }
        var classDesc = e.className && ("." + e.className.replace(/ /g, "."));
        var elDesc = "";
        if (e.id)
          elDesc = "(#" + e.id + classDesc + ")";
        else if (classDesc)
          elDesc = "(" + classDesc + ")";
        return rv + elDesc;
      };
      this.log = function () {
        if (typeof dump !== "undefined") {
          var msg = Array.prototype.map.call(arguments, function(x) {
            return (x && x.nodeName) ? logEl(x) : x;
          }).join(" ");
          dump("Reader: (Readability) " + msg + "\n");
        } else if (typeof console !== "undefined") {
          var args = ["Reader: (Readability) "].concat(arguments);
          console.log.apply(console, args);
        }
      };
    } else {
      this.log = function () {};
    }
  }