<commit_before>'use strict';
try {
  var memwatch = require('memwatch');
  memwatch.on('leak', function(info) {
    console.log("leak", info);
  });
  console.log("Watching for memory leaks");
} catch (e) {
  console.log("Not watching for memory leaks -- npm install memwatch to do so");
}

var config = {
  port: 1337
};

// Move this to Redis
var connectedDevices = {}
  , connectedBrowsers = {};

var cluster = require('cluster');
if (cluster.isMaster) {

  // One worker for now -- but later can check # of cpus
  cluster.fork();

  cluster.on('disconnect', function(worker) {
    console.error("disconnect!");
    cluster.fork();
  });

} else {
  // the worker

  var Primus = require('primus')
    , http = require('http')
    , domain = require('domain')
    , server = http.createServer()
    , primusSpec = { transformer: 'sockjs', parser: 'json' }
    , primus = new Primus(server, primusSpec);

  primus.on('connection', function connection(spark) {

    var d = domain.create();

    d.on('error', function(err) {<commit_msg>reduce jshint complaints<commit_after>try {
  var memwatch = require('memwatch');
  memwatch.on('leak', function(info) {
    console.log("leak", info);
  });
  console.log("Watching for memory leaks");
} catch (e) {
  console.log("Not watching for memory leaks -- npm install memwatch to do so");
}

var config = {
  port: 1337
};

// Move this to Redis
var connectedDevices = {},
    connectedBrowsers = {};

var cluster = require('cluster');
if (cluster.isMaster) {

  // One worker for now -- but later can check # of cpus
  cluster.fork();

  cluster.on('disconnect', function(worker) {
    console.error("disconnect!");
    cluster.fork();
  });

} else {
  // the worker

  var Primus = require('primus'),
      http = require('http'),
      domain = require('domain'),
      server = http.createServer(),
      primusSpec = { transformer: 'sockjs', parser: 'json' },
      primus = new Primus(server, primusSpec);

  primus.on('connection', function connection(spark) {
    "use strict";

    var d = domain.create();

    d.on('error', function(err) {
{'fraction_non_alphanumeric': 0.16213638531235097, 'fraction_numerical': 0.003814973772055317, 'mean_word_length': 3.4355179704016914, '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': '2785164', 'n_tokens_mistral': 687, 'n_tokens_neox': 654, 'n_words': 176}