<commit_before>;(function (root) {
  'use strict';

  var keys = Object.keys,
      isArray = Array.isArray,
      isObject = function (obj) {
        return typeof obj === 'object' && !!obj;
      };

  var Relate = {};

  Relate.VERSION = '/*VERSION*/'; // automatically generated in build process

  // Maps

  var map = Relate.map = {};

  Relate._map = function (map) {

    var inverse = {},
        results = {};

    keys(map || {}).forEach(function (key) {
      inverse[map[key]] = key;
    });

    keys(Relate.collections).forEach(function (name) {
      if (inverse[name])
        results[inverse[name]] = name;
      else
        results[name] = name;
    });

    return results;
  };

  // Transforms

  var transform = Relate.transform = {};
  Relate.defaultTransform = function (item, collection) { return item; };

  // Relate.Collection

  var Collection = Relate.Collection = function (name, options) {
    var self = this;
    options = options || {};

    self.name = name;
    self.store = {};

    self._map = options.map || {};
    self._transform = options.transform;
  };

  Collection.prototype.map = function () {
    var self = this;
<commit_msg>Allow multiple mappings to the same collection in each item<commit_after>;(function (root) {
  'use strict';

  var keys = Object.keys,
      isArray = Array.isArray,
      isObject = function (obj) {
        return typeof obj === 'object' && !!obj;
      };

  var Relate = {};

  Relate.VERSION = '/*VERSION*/'; // automatically generated in build process

  // Maps

  var map = Relate.map = {};

  Relate._map = function (map) {

    var mapped = {},
        results = {};

    keys(map || {}).forEach(function (key) {
      mapped[map[key]] = true;
      results[key] = map[key];
    });

    keys(Relate.collections).forEach(function (name) {
      if (!mapped[name])
        results[name] = name;
    });

    return results;
  };

  // Transforms

  var transform = Relate.transform = {};
  Relate.defaultTransform = function (item, collection) { return item; };

  // Relate.Collection

  var Collection = Relate.Collection = function (name, options) {
    var self = this;
    options = options || {};

    self.name = name;
    self.store = {};

    self._map = options.map || {};
    self._transform = options.transform;
  };

  Collection.prototype.map = function () {
    var self = this;

{'fraction_non_alphanumeric': 0.15336134453781514, 'fraction_numerical': 0.0, 'mean_word_length': 2.486090775988287, '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': '1012717', 'n_tokens_mistral': 739, 'n_tokens_neox': 702, 'n_words': 180}