<commit_before>
/**
 * Module dependencies.
 */

var tty = require('tty');

/**
 * This is the Node.js implementation of `debug()`.
 *
 * Expose `debug()` as the module.
 */

exports = module.exports = require('./debug');
exports.log = log;
exports.save = save;
exports.load = load;

/**
 * Colors.
 */

var colors = [6, 2, 3, 4, 5, 1];

/**
 * Previously assigned color.
 */

var prevColor = 0;

/**
 * Is stdout a TTY? Colored output is disabled when `true`.
 */

var useColors = tty.isatty(1) || process.env.DEBUG_COLORS;

/**
 * Select a color.
 *
 * @return {Number}
 * @api private
 */

function selectColor() {
  return colors[prevColor++ % colors.length];
}

/**
 * Invokes `console.log()` with the specified arguments,
 * after adding ANSI color escape codes if enabled.
 *
 * @api public
 */

function log(fmt) {
  var name = this.namespace;

  if (useColors) {
    if (null == this.c) this.c = selectColor();

    var c = this.c;
    var curr = new Date();
    var ms = curr - (this.prev || curr);
    this.prev = curr;

    fmt = '  \u001b[9' + c + 'm' + name + ' '
      + '\u001b[3' + c + 'm\u001b[90m'
      + fmt + '\u001b[3' + c + 'm'
      + ' +' + exports.humanize(ms) + '\u001b[0m';
  } else {
    fmt = new Date().toUTCString()
      + ' ' + name + ' ' + fmt;
  }

  console.log.apply(console, arguments);
}

/**
 * Save `namespaces
 *
 * @param {String} namespaces
 * @api private
 */

function save(namespaces) {
  process.env.DEBUG = namespaces;
}

/**
 * Load `namespaces`.
 *
 * @return {String} returns the previously persisted debug modes
 * @api private
 */

function load() {
  return process.env.DEBUG;
}

/**<commit_msg>node: fix colors in strict mode<commit_after>
/**
 * Module dependencies.
 */

var tty = require('tty');

/**
 * This is the Node.js implementation of `debug()`.
 *
 * Expose `debug()` as the module.
 */

exports = module.exports = require('./debug');
exports.log = log;
exports.save = save;
exports.load = load;

/**
 * Colors.
 */

var colors = [6, 2, 3, 4, 5, 1];

/**
 * Previously assigned color.
 */

var prevColor = 0;

/**
 * Is stdout a TTY? Colored output is disabled when `true`.
 */

var useColors = tty.isatty(1) || process.env.DEBUG_COLORS;

/**
 * Select a color.
 *
 * @return {Number}
 * @api private
 */

function selectColor() {
  return colors[prevColor++ % colors.length];
}

/**
 * Invokes `console.log()` with the specified arguments,
 * after adding ANSI color escape codes if enabled.
 *
 * @api public
 */

function log() {
  var args = arguments;
  var name = this.namespace;

  if (useColors) {
    if (null == this.c) this.c = selectColor();

    var c = this.c;
    var curr = new Date();
    var ms = curr - (this.prev || curr);
    this.prev = curr;

    args[0] = '  \u001b[9' + c + 'm' + name + ' '
      + '\u001b[3' + c + 'm\u001b[90m'
      + args[0] + '\u001b[3' + c + 'm'
      + ' +' + exports.humanize(ms) + '\u001b[0m';
  } else {
    args[0] = new Date().toUTCString()
      + ' ' + name + ' ' + args[0];
  }

  console.log.apply(console, args);
}

/**
 * Save `namespaces
 *
 * @param {String} namespaces
 * @api private
 */

function save(namespaces) {
  process.env.DEBUG = namespaces;
}

/**
 * Load `namespaces`.
 *
 * @return {String} returns the previously persisted debug modes
 * @api private
 */

function load() {
  return process.env.DEBUG;
}

/**
{'fraction_non_alphanumeric': 0.18097793679189028, 'fraction_numerical': 0.018485390578413835, 'mean_word_length': 2.7195121951219514, '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': '3964098', 'n_tokens_mistral': 1249, 'n_tokens_neox': 1210, 'n_words': 326}