<commit_before>require 'ransible/version'
require_relative 'ransible/arguments_file'
require_relative 'ransible/result'

# The entrypoint to the module
module Ransible
  def self.module
    result = Result.new
    yield result, arguments
    print JSON.dump(result.changes)
  rescue FailError => e
    print JSON.dump failed: true, msg: e.message
  end

  def self.arguments
    ArgumentsFile.new(ARGV[0]).to_hash
  end
  private_class_method :arguments
end<commit_msg>drop parens to be more idiomatic<commit_after>require 'ransible/version'
require_relative 'ransible/arguments_file'
require_relative 'ransible/result'

# The entrypoint to the module
module Ransible
  def self.module
    result = Result.new
    yield result, arguments
    print JSON.dump result.changes
  rescue FailError => e
    print JSON.dump failed: true, msg: e.message
  end

  def self.arguments
    ArgumentsFile.new(ARGV[0]).to_hash
  end
  private_class_method :arguments
end
{'fraction_non_alphanumeric': 0.07322175732217573, 'fraction_numerical': 0.0020920502092050207, 'mean_word_length': 4.287292817679558, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '7271053', 'n_tokens_mistral': 299, 'n_tokens_neox': 291, 'n_words': 83}