<commit_before>require 'logger'

module Flex
  class Logger < ::Logger


    attr_accessor :debug_variables, :debug_request, :debug_result, :curl_format

    def initialize(*)
      super
      self.level     = ::Logger::INFO
      self.progname  = 'FLEX'
      self.formatter = proc do |severity, datetime, progname, msg|
        flex_format(severity, msg)
      end
      @debug_variables = true
      @debug_request   = true
      @debug_result    = true
      @curl_format     = false
    end

    def flex_format(severity, msg)
      prefix = Dye.dye(" FLEX-#{severity} ", "FLEX-#{severity}:", :blue, :bold, :reversed) + ' '
      msg.split("\n").map{|l| prefix + l}.join("\n") + "\n"
    end

    # force color in console (used with jruby)
    def color=(bool)
      Dye.color = bool
    end

    def color
      Dye.color?
    end

  end
end
<commit_msg>raised the default logger level to WARN<commit_after>require 'logger'

module Flex
  class Logger < ::Logger


    attr_accessor :debug_variables, :debug_request, :debug_result, :curl_format

    def initialize(*)
      super
      self.level     = ::Logger::WARN
      self.progname  = 'FLEX'
      self.formatter = proc do |severity, datetime, progname, msg|
        flex_format(severity, msg)
      end
      @debug_variables = true
      @debug_request   = true
      @debug_result    = true
      @curl_format     = false
    end

    def flex_format(severity, msg)
      prefix = Dye.dye(" FLEX-#{severity} ", "FLEX-#{severity}:", :blue, :bold, :reversed) + ' '
      msg.split("\n").map{|l| prefix + l}.join("\n") + "\n"
    end

    # force color in console (used with jruby)
    def color=(bool)
      Dye.color = bool
    end

    def color
      Dye.color?
    end

  end
end

{'fraction_non_alphanumeric': 0.12356979405034325, 'fraction_numerical': 0.0, 'mean_word_length': 2.396116504854369, 'pattern_counts': {'":': 0, '<': 5, '<?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': '6567998', 'n_tokens_mistral': 619, 'n_tokens_neox': 572, 'n_words': 148}