<commit_before>module RSpotify

  class Album < Base

    attr_accessor :album_type, :images, :name, :tracks

    def self.find(id)
      super(id, 'album')
    end

    def self.search(query, limit = 20, offset = 0)
      super(query, 'album', limit, offset)
    end

    def initialize(options = {})
      @album_type = options['album_type']
      @images     = options['images']
      @name       = options['name']

      if options['tracks']
        tracks = options['tracks']['items']
        @tracks = tracks.map { |t| Track.new t }
      end

      super(options)
    end

  end
end<commit_msg>adding attributes to Album<commit_after>module RSpotify

  class Album < Base

    attr_accessor :album_type, :artists, :available_markets, :external_ids, :genres, :images,
                  :name, :popularity, :release_date, :release_date_precision, :tracks

    def self.find(id)
      super(id, 'album')
    end

    def self.search(query, limit = 20, offset = 0)
      super(query, 'album', limit, offset)
    end

    def initialize(options = {})
      @album_type             = options['album_type']
      @artists                = options['artists'].map { |a| Artist.new a }
      @available_markets      = options['available_markets']
      @external_ids           = options['external_ids']
      @genres                 = options['genres']
      @images                 = options['images']
      @name                   = options['name']
      @popularity             = options['popularity']
      @release_date           = options['release_date']
      @release_date_precision = options['release_date_precision']

      if options['tracks']
        tracks = options['tracks']['items']
        @tracks = tracks.map { |t| Track.new t }
      end

      super(options)
    end

  end
end
{'fraction_non_alphanumeric': 0.12256267409470752, 'fraction_numerical': 0.003342618384401114, 'mean_word_length': 2.2244165170556554, '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': '2091790', 'n_tokens_mistral': 556, 'n_tokens_neox': 513, 'n_words': 122}