code: function (obj, contents, weight, categoryWeights) {
          obj._gloss.parse(contents);
          var current = obj._gloss.root;
          var prev = null;
          do {
              var s = current.toJSON();
              if (!s.children && !s.orig && !s.isFiltered) {
                  // increment total and add/incr bidirectional edges for current node
                  prev = obj._incrEdges(id, obj._fmtNode(s), prev, weight, categoryWeights);
              } else if (!s.isFiltered) {
                  if (s.orig && s.children) {
                      // increment total and add bidirectional edge weight for original node
                      if (!s.orig.isFiltered) {
                          prev = obj._incrEdges(id, obj._fmtNode(s.orig), prev, weight, categoryWeights);
                      }
  
                      for (var i = 0; i < s.children.length; i++) {
                          // increment total and add/incr bidirectional edges on child
                          if (!s.children[i].isFiltered) {
                              prev = obj._incrEdges(id, obj._fmtNode(s.children[i]), prev, weight, categoryWeights);
                          }
                      }
                  }
              }
  
              current = current.next;
          } while (current);
      }
docs: parse the text (tokenize, tag..etc)