<commit_before>class Track
  attr_reader :name, :track_number, :popularity

  def initialize(
    name,
    track_number:,
    popularity:
  )
    @name = name
    @track_number = track_number
    @popularity = popularity
  end

  def self.from_json(data)
    Track.new(
      data['name'],
      track_number: data['track_number'],
      popularity: data['popularity'],
    )
  end
end<commit_msg>Store the duration of each track<commit_after>class Track
  attr_reader :name, :track_number, :duration_seconds, :popularity

  def initialize(
    name,
    track_number:,
    duration_seconds:,
    popularity:
  )
    @name = name
    @track_number = track_number
    @duration_seconds = duration_seconds
    @popularity = popularity
  end

  def self.from_json(data)
    Track.new(
      data['name'],
      track_number: data['track_number'],
      duration_seconds: data['duration_ms'] / 1000.0,
      popularity: data['popularity'],
    )
  end
end
{'fraction_non_alphanumeric': 0.10504201680672269, 'fraction_numerical': 0.005252100840336135, 'mean_word_length': 3.198237885462555, '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': '447533', 'n_tokens_mistral': 313, 'n_tokens_neox': 302, 'n_words': 67}