<commit_before>require 'rubygems'
require 'rbconfig'
require 'spec'

if ENV["MRI_FFI"]
  $:.unshift File.join(File.dirname(__FILE__), "..", "..", "lib"),
    File.join(File.dirname(__FILE__), "..", "..", "build", "#{Config::CONFIG['host_cpu''arch']}", "ffi_c", RUBY_VERSION)
end
require "ffi"
<commit_msg>Remove lib/ from load path when running under JRuby<commit_after>require 'rubygems'
require 'rbconfig'
require 'spec'

if RUBY_PLATFORM =~/java/
  libdir = File.expand_path(File.join(File.dirname(__FILE__), "..", "..", "lib"))
  $:.reject! { |p| p == libdir }
else
  $:.unshift File.join(File.dirname(__FILE__), "..", "..", "lib"),
    File.join(File.dirname(__FILE__), "..", "..", "build", "#{Config::CONFIG['host_cpu''arch']}", "ffi_c", RUBY_VERSION)
end
puts "loadpath=#{$:.join(':')}"
require "ffi"

{'fraction_non_alphanumeric': 0.24504950495049505, 'fraction_numerical': 0.0, 'mean_word_length': 5.3203125, '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': '203101', 'n_tokens_mistral': 321, 'n_tokens_neox': 298, 'n_words': 57}