<commit_before>require 'digest/md5'
require 'scene_toolkit/release/helpers'
require 'scene_toolkit/release/rename'
require 'scene_toolkit/release/validations'
require 'scene_toolkit/release/validations/checksum'
require 'scene_toolkit/release/validations/name'
require 'scene_toolkit/release/validations/playlist'
require 'scene_toolkit/release/validations/required_files'

module SceneToolkit
  class Release
    attr_accessor :name, :path, :uid
    attr_accessor :errors, :warnings

    include Validations
    include Rename
    include Helpers

    include Validations::Checksum
    include Validations::Name
    include Validations::Playlist
    include Validations::RequiredFiles

    def initialize(path)
      @path = File.expand_path(path)
      @name = File.basename(path)
      @uid = Digest::MD5.hexdigest(@name.downcase.gsub(/[^A-Z0-9]/i, ' ').gsub(/\s+/, ' '))
      @errors, @warnings = { }, { }
    end

    def files
      Dir.glob(File.join(@path, "*"))
    end
  end
end<commit_msg>Do not calculate release UID as it's still not yet used.<commit_after>require 'scene_toolkit/release/helpers'
require 'scene_toolkit/release/rename'
require 'scene_toolkit/release/validations'
require 'scene_toolkit/release/validations/checksum'
require 'scene_toolkit/release/validations/name'
require 'scene_toolkit/release/validations/playlist'
require 'scene_toolkit/release/validations/required_files'

module SceneToolkit
  class Release
    attr_accessor :name, :path
    attr_accessor :errors, :warnings

    include Validations
    include Rename
    include Helpers

    include Validations::Checksum
    include Validations::Name
    include Validations::Playlist
    include Validations::RequiredFiles

    def initialize(path)
      @path = File.expand_path(path)
      @name = File.basename(path)
      @errors, @warnings = { }, { }
    end

    def files
      Dir.glob(File.join(@path, "*"))
    end
  end
end
{'fraction_non_alphanumeric': 0.1043613707165109, 'fraction_numerical': 0.0020768431983385254, 'mean_word_length': 4.152406417112299, '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': '4123930', 'n_tokens_mistral': 605, 'n_tokens_neox': 596, 'n_words': 121}