<commit_before>Alm::Application.routes.draw do
  mount JasmineRails::Engine => '/specs' if defined?(JasmineRails)

  devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks", :registrations => "users/registrations" }

  root :to => "docs#index"

  # constraints is added to allow dot in the url (doi is used to show article)
  resources :articles, :constraints => { :id => /.+?/, :format => /html/}

  resources :sources
  resources :users
  resources :docs, :only => [:index, :show], :constraints => { :id => /[0-z\-\.\(\)]+/ }

  match "oembed" => "oembed#show"

  namespace :admin do
    root :to => "status#index"
    resources :articles, :constraints => { :id => /.+?/, :format => /html|js/ }
    resources :sources
    resources :errors
    resources :alerts
    resources :api_requests
    resources :users
    resources :filters
  end

  namespace :api do
    namespace :v3 do
      root :to => "articles#index"
      resources :articles, :constraints => { :id => /.+?/, :format=> false }, only: [:index, :show]
      resources :sources, :constraints => { :format=> false }, only: [:index, :show]
      resources :status, :constraints => { :format=> false }, only: [:index]
      resources :api_requests, :constraints => { :format=> false }, only: [:index]
    end

    namespace :v4 do
      root :to => "articles#index"
      resources :articles, :constraints => { :id => /.+?/, :format=> false }
    end

    namespace :v5 do
      root :to => "articles#index"
      resources :articles, :constraints => { :id => /.+?/, :format=> false }, only: [:index]
      resources :sources, :constraints => { :format=> false }, only: [:index, :show]
      resources :status, :constraints => { :format=> false }, only: [:index]
      resources :api_requests, :constraints => { :format=> false }, only: [:index]
    end
  end
end<commit_msg>route v4 APi index action to v5 API<commit_after>Alm::Application.routes.draw do
  mount JasmineRails::Engine => '/specs' if defined?(JasmineRails)

  devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks", :registrations => "users/registrations" }

  root :to => "docs#index"

  # constraints is added to allow dot in the url (doi is used to show article)
  resources :articles, :constraints => { :id => /.+?/, :format => /html/}

  resources :sources
  resources :users
  resources :docs, :only => [:index, :show], :constraints => { :id => /[0-z\-\.\(\)]+/ }

  match "oembed" => "oembed#show"

  namespace :admin do
    root :to => "status#index"
    resources :articles, :constraints => { :id => /.+?/, :format => /html|js/ }
    resources :sources
    resources :errors
    resources :alerts
    resources :api_requests
    resources :users
    resources :filters
  end

  namespace :api do
    namespace :v3 do
      root :to => "articles#index"
      resources :articles, :constraints => { :id => /.+?/, :format=> false }, only: [:index, :show]
      resources :sources, :constraints => { :format=> false }, only: [:index, :show]
      resources :status, :constraints => { :format=> false }, only: [:index]
      resources :api_requests, :constraints => { :format=> false }, only: [:index]
    end

    namespace :v4 do
      root :to => Api::V5::ArticlesController.action(:index)
      resources :articles, :constraints => { :id => /.+?/, :format=> false }
    end

    namespace :v5 do
      root :to => "articles#index"
      resources :articles, :constraints => { :id => /.+?/, :format=> false }, only: [:index]
      resources :sources, :constraints => { :format=> false }, only: [:index, :show]
      resources :status, :constraints => { :format=> false }, only: [:index]
      resources :api_requests, :constraints => { :format=> false }, only: [:index]
    end
  end
end
{'fraction_non_alphanumeric': 0.1751188589540412, 'fraction_numerical': 0.0029054410987849975, 'mean_word_length': 3.378034682080925, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 83, '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': '5902288', 'n_tokens_mistral': 1230, 'n_tokens_neox': 1179, 'n_words': 348}