<commit_before>require 'rubygems' if __FILE__ == $0
require 'zlib'
require 'yaml'
require 'redis'
require 'redis/hash_ring'
require 'redis/namespace'

class Redi

  def self.get(key)
    pool.redis_by_key(key).get(key)
  end

  def self.set(key, val)
    pool.redis_by_key(key).set(key, val)
  end

  def self.flushall
    @pool.flushall
  end

  def self.mock!
    pool.mock!
  end

  def self.pool
    @pool ||= Pool.new(self.config)<commit_msg>fix flush bug<commit_after>require 'rubygems' if __FILE__ == $0
require 'zlib'
require 'yaml'
require 'redis'
require 'redis/hash_ring'
require 'redis/namespace'

class Redi

  def self.get(key)
    pool.redis_by_key(key).get(key)
  end

  def self.set(key, val)
    pool.redis_by_key(key).set(key, val)
  end

  def self.flushall
    pool.flushall
  end

  def self.mock!
    pool.mock!
  end

  def self.pool
    @pool ||= Pool.new(self.config)
{'fraction_non_alphanumeric': 0.12430011198208286, 'fraction_numerical': 0.0022396416573348264, 'mean_word_length': 3.4477611940298507, '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': '45306', 'n_tokens_mistral': 364, 'n_tokens_neox': 352, 'n_words': 79}