diff --git a/lib/twitter_ebooks/nlp.rb b/lib/twitter_ebooks/nlp.rb index 3fb9ea3..f971f0c 100644 --- a/lib/twitter_ebooks/nlp.rb +++ b/lib/twitter_ebooks/nlp.rb @@ -14,10 +14,10 @@ module Ebooks # to be using it all of the time # Lazily loads an array of stopwords - # Stopwords are common English words that should often be ignored + # Stopwords are common words that should often be ignored # @return [Array] def self.stopwords - @stopwords ||= File.read(File.join(DATA_PATH, 'stopwords.txt')).split + @stopwords ||= File.exists?('stopwords.txt') ? File.read('stopwords.txt').split : [] end # Lazily loads an array of known English nouns diff --git a/data/stopwords.txt b/skeleton/stopwords.txt similarity index 100% rename from data/stopwords.txt rename to skeleton/stopwords.txt