<commit_before>'use strict'
/**
 * @id define
 * @function define
 * Defines new (or modifies existing) properties (using [`Object.defineProperty`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Object/defineProperty)) on an object passed to `define` as `this`, setting `configurable: true` by default
 * @param {object} props - Properties to set
 */
module.exports = define

function define () {
  var val
  for (let i = 0, length = arguments.length; i < length; i++) {
    val = arguments[i]
    for (let key in val) {
      let definition = val[key]
      let type = typeof definition
      if (key === 'extend' && type === 'object') {
        console.log('lets try to extend!')
        extend(this, definition)
      } else {
        if (type === 'function' || type !== 'object' || 'isBase' in definition) {
          definition = { value: definition }
        }
        definition.configurable = true
        Object.defineProperty(this, key, definition)
      }
    }
  }
}

function extend (target, val) {
  for (let key in val) {
    if (typeof val[key] !== 'function') {
      throw new Error(`Expect function for extension "${key}"`)
    }
    val[key] = (target.define || define)
      .call(target, { [key]: createExtension(val[key], target[key]) })
  }
}

function createExtension (val, target) {
  return function extension () {
    const len = arguments.length
    const args = new Array(len + 1)
    args[0] = target<commit_msg>remove log<commit_after>'use strict'
/**
 * @id define
 * @function define
 * Defines new (or modifies existing) properties (using [`Object.defineProperty`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Object/defineProperty)) on an object passed to `define` as `this`, setting `configurable: true` by default
 * @param {object} props - Properties to set
 */
module.exports = define

function define () {
  var val
  for (let i = 0, length = arguments.length; i < length; i++) {
    val = arguments[i]
    for (let key in val) {
      let definition = val[key]
      let type = typeof definition
      if (key === 'extend' && type === 'object') {
        extend(this, definition)
      } else {
        if (type === 'function' || type !== 'object' || 'isBase' in definition) {
          definition = { value: definition }
        }
        definition.configurable = true
        Object.defineProperty(this, key, definition)
      }
    }
  }
}

function extend (target, val) {
  for (let key in val) {
    if (typeof val[key] !== 'function') {
      throw new Error(`Expect function for extension "${key}"`)
    }
    val[key] = (target.define || define)
      .call(target, { [key]: createExtension(val[key], target[key]) })
  }
}

function createExtension (val, target) {
  return function extension () {
    const len = arguments.length
    const args = new Array(len + 1)
    args[0] = target
{'fraction_non_alphanumeric': 0.1419710544452102, 'fraction_numerical': 0.002067539627842867, 'mean_word_length': 2.9931224209078406, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 2, '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': '4116511', 'n_tokens_mistral': 852, 'n_tokens_neox': 841, 'n_words': 264}