<commit_before>module MetricFu
  BASE_DIRECTORY = ENV['CC_BUILD_ARTIFACTS'] || 'tmp/metric_fu'
  RAILS = File.exist?("config/environment.rb")
  
  if RAILS
    MetricFu::CODE_DIRS = ['app']
  else
    MetricFu::CODE_DIRS = ['lib']
  end
end

require File.join(File.dirname(__FILE__), 'metric_fu', 'md5_tracker')
require File.join(File.dirname(__FILE__), 'metric_fu', 'flog_reporter')
require File.join(File.dirname(__FILE__), 'tasks', 'metric_fu')<commit_msg>Include both app and lib in rails apps<commit_after>module MetricFu
  BASE_DIRECTORY = ENV['CC_BUILD_ARTIFACTS'] || 'tmp/metric_fu'
  RAILS = File.exist?("config/environment.rb")
  
  if RAILS
    MetricFu::CODE_DIRS = ['app', 'lib']
  else
    MetricFu::CODE_DIRS = ['lib']
  end
end

require File.join(File.dirname(__FILE__), 'metric_fu', 'md5_tracker')
require File.join(File.dirname(__FILE__), 'metric_fu', 'flog_reporter')
require File.join(File.dirname(__FILE__), 'tasks', 'metric_fu')
{'fraction_non_alphanumeric': 0.15473684210526314, 'fraction_numerical': 0.002105263157894737, 'mean_word_length': 5.9416058394160585, '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': '2079900', 'n_tokens_mistral': 366, 'n_tokens_neox': 350, 'n_words': 63}