def praposes(a): #a = teks a = pps.preprocessing(a) a = pps.removePunc(a) a = ct.norm_typo(a) a = nkbi.norm_kbbi(a) a = stm.stemmer_kata(a) a = stm.stop_word(a) return a
def praposes(a, normalisasi=True): #a = teks if normalisasi == True: a = pps.gantiKarakter(a) a = pps.preprocessing(a) a = pps.removePunc(a) if normalisasi == True: a = ct.cek_typo(a) a = nkbi.norm_kbbi(a) a = stm.stemmer_kata(a) a = stm.stop_word(a) return a
def praproses(teks): a = tknzr.tokenize(teks) a = " ".join(a) a = pps.preprocessing(teks) a = pps.removePunc(a) a = ct.norm_typo(a) a = nkbi.norm_kbbi(a) a = stm.stemmer_kata(a) a = re.sub(' +', ' ',a) a = a.lstrip() return a
def saves(): stm.save_kta()
def savek(): nkbi.save_gdiganti() ct.save_gdiganti() stm.save_kta()
def stem_dulu(list_kata): n_list = list() for i in list_kata: i = stm.stemmer_kata(i) n_list.append(i) return list(set(n_list))