add ti-idf and cosine method