<commit_before>module FindByDateInterval

  # Returns entity objects for a given interval of days.
  def find_by_date_interval(from, unto)
    response = session.request entity_class.soap_action("FindByDateInterval") do
      soap.body = {
        'first' => from.iso8601,
        'last' => unto.iso8601,
        :order! => ['first', 'last']
      }
    end

    handle_key = "#{Economic::Support::String.underscore(entity_class_name)}_handle".intern
    handles = [ response[handle_key] ].flatten.reject(&:blank?).collect do |handle|
      Economic::Entity::Handle.new(handle)
    end

    get_data_array(handles).collect do |entity_hash|
      entity = build(entity_hash)
      entity.persisted = true
      entity
    end
  end

end<commit_msg>FindByDateInterval should live inside the Economic namespace<commit_after>module Economic
  module FindByDateInterval

    # Returns entity objects for a given interval of days.
    def find_by_date_interval(from, unto)
      response = session.request entity_class.soap_action("FindByDateInterval") do
        soap.body = {
          'first' => from.iso8601,
          'last' => unto.iso8601,
          :order! => ['first', 'last']
        }
      end

      handle_key = "#{Support::String.underscore(entity_class_name)}_handle".intern
      handles = [ response[handle_key] ].flatten.reject(&:blank?).collect do |handle|
        Entity::Handle.new(handle)
      end

      get_data_array(handles).collect do |entity_hash|
        entity = build(entity_hash)
        entity.persisted = true
        entity
      end
    end

  end
end
{'fraction_non_alphanumeric': 0.10865445356917246, 'fraction_numerical': 0.01010739102969046, 'mean_word_length': 3.020304568527919, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, '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': '1212302', 'n_tokens_mistral': 491, 'n_tokens_neox': 467, 'n_words': 102}