<commit_before>// this is gross but it monkey patches in behaviour required by `depd` used by
// `ast-types`
Error.captureStackTrace = Error.captureStackTrace || function (obj) {
  if (Error.prepareStackTrace) {
    var frame = {
      isEval: function () { return false; },
      getFileName: function () { return "filename"; },
      getLineNumber: function () { return 1; },
      getColumnNumber: function () { return 1; },
      getFunctionName: function () { return "functionName"; }
    };

    obj.stack = Error.prepareStackTrace(obj, [frame, frame, frame]);
  } else {
    obj.stack = obj.stack || obj.name || "Error";
  }
};

var transform = module.exports = require("./transform");
var generate  = require("./generator");

transform.transform = transform;
transform.generate  = generate;

transform.eval = function (code, opts) {
  opts = opts || {};
  opts.filename = opts.filename || "eval";
  opts.sourceMap = "inline";
  return eval(transform(code, opts).code);
};

transform.run = function (code, opts) {<commit_msg>remove exposure to generator from browser build<commit_after>// this is gross but it monkey patches in behaviour required by `depd` used by
// `ast-types`
Error.captureStackTrace = Error.captureStackTrace || function (obj) {
  if (Error.prepareStackTrace) {
    var frame = {
      isEval: function () { return false; },
      getFileName: function () { return "filename"; },
      getLineNumber: function () { return 1; },
      getColumnNumber: function () { return 1; },
      getFunctionName: function () { return "functionName"; }
    };

    obj.stack = Error.prepareStackTrace(obj, [frame, frame, frame]);
  } else {
    obj.stack = obj.stack || obj.name || "Error";
  }
};

var transform = module.exports = require("./transform");

transform.transform = transform;

transform.eval = function (code, opts) {
  opts = opts || {};
  opts.filename = opts.filename || "eval";
  opts.sourceMap = "inline";
  return eval(transform(code, opts).code);
};

transform.run = function (code, opts) {
{'fraction_non_alphanumeric': 0.14955577492596248, 'fraction_numerical': 0.0019743336623889436, 'mean_word_length': 3.6173120728929384, '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': '2805323', 'n_tokens_mistral': 581, 'n_tokens_neox': 572, 'n_words': 167}