<commit_before>#!/usr/bin/env ruby

require 'environment'
require 'lib/sinatra/lib/sinatra'

get('/') { redirect "/#{HOMEPAGE}" }

# page paths

get '/:page' do
  @page = Page.new(params[:page])
  @page.tracked? ? show(:show, @page.name) : redirect('/e/' + @page.name)
end

get '/:page/raw' do
  @page = Page.new(params[:page])
  @page.raw_body
end<commit_msg>require sinatra above git-wiki directory until there's a good way to freeze it in<commit_after>#!/usr/bin/env ruby

require 'environment'
require '../sinatra/lib/sinatra'

get('/') { redirect "/#{HOMEPAGE}" }

# page paths

get '/:page' do
  @page = Page.new(params[:page])
  @page.tracked? ? show(:show, @page.name) : redirect('/e/' + @page.name)
end

get '/:page/raw' do
  @page = Page.new(params[:page])
  @page.raw_body
end
{'fraction_non_alphanumeric': 0.19822109275730623, 'fraction_numerical': 0.0, 'mean_word_length': 4.150326797385621, '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': '6106864', 'n_tokens_mistral': 297, 'n_tokens_neox': 297, 'n_words': 70}