<commit_before>'use strict';

var zookeeper = require('node-zookeeper-client');
var Q = require('Q');
var _ = require('lodash');


var PathChildrenCache = function (framework, path) {
  this.framework = framework;
  this.path = path;
  // path watcher for finding new nodes
  var context = this;
  this.watcher = function () {
    context.rebuild();
  };
};


PathChildrenCache.prototype.start = function () {
  this.cache = {};
  return this.rebuild();
};

PathChildrenCache.prototype.rebuild = function () {
  var defer = Q.defer();
  var context = this;
  this.framework
    .getZkClient()
    .getChildren(this.path,function (error, children) {
      _.forEach(children, function (child) {<commit_msg>lowercase q<commit_after>'use strict';

var zookeeper = require('node-zookeeper-client');
var Q = require('q');
var _ = require('lodash');


var PathChildrenCache = function (framework, path) {
  this.framework = framework;
  this.path = path;
  // path watcher for finding new nodes
  var context = this;
  this.watcher = function () {
    context.rebuild();
  };
};


PathChildrenCache.prototype.start = function () {
  this.cache = {};
  return this.rebuild();
};

PathChildrenCache.prototype.rebuild = function () {
  var defer = Q.defer();
  var context = this;
  this.framework
    .getZkClient()
    .getChildren(this.path,function (error, children) {
      _.forEach(children, function (child) {
{'fraction_non_alphanumeric': 0.14488636363636365, 'fraction_numerical': 0.0, 'mean_word_length': 3.8253424657534247, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4748158', 'n_tokens_mistral': 443, 'n_tokens_neox': 434, 'n_words': 105}