added extracting ngrams