<commit_before>module ProxyMgr
  class Haproxy
    require 'thread'
    require 'zlib'
    require 'tempfile'
    require 'pathname'
    require 'erb'
    require 'proxymgr/process_manager'
    require 'proxymgr/haproxy/socket'
    require 'proxymgr/haproxy/updater'
    require 'proxymgr/haproxy/server'
    require 'proxymgr/haproxy/control'
    require 'proxymgr/haproxy/process'
    require 'proxymgr/haproxy/state'

    include Logging

    def initialize(path, config_file, opts = {})
      @path             = path
      @config_file      = config_file

      @socket_path      = opts[:socket]
      @global_config    = opts[:global]
      @defaults_config  = opts[:defaults]

      @socket           = @socket_path ? Socket.new(@socket_path) : nil

      @control          = nil
    end

    def version
      `#{@path} -v`[/version ([\d\.]+)/, 1].to_f<commit_msg>Misc cleanup<commit_after>module ProxyMgr
  class Haproxy
    require 'proxymgr/haproxy/socket'
    require 'proxymgr/haproxy/updater'
    require 'proxymgr/haproxy/server'
    require 'proxymgr/haproxy/control'
    require 'proxymgr/haproxy/process'
    require 'proxymgr/haproxy/state'

    def initialize(path, config_file, opts = {})
      @path             = path
      @config_file      = config_file

      @socket_path      = opts[:socket]
      @global_config    = opts[:global]
      @defaults_config  = opts[:defaults]

      @socket           = @socket_path ? Socket.new(@socket_path) : nil

      @control          = nil
    end

    def version
      `#{@path} -v`[/version ([\d\.]+)/, 1].to_f
{'fraction_non_alphanumeric': 0.11589613679544016, 'fraction_numerical': 0.001266624445851805, 'mean_word_length': 2.4051724137931036, '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': '5594946', 'n_tokens_mistral': 560, 'n_tokens_neox': 539, 'n_words': 100}