可视化Textrank中的句子网络

时间:2019-06-21 11:15:59

标签: r graph nlp text-mining summarization

我正在使用解释为here的Textrank方法来获取文本摘要。有没有办法像所有相互连接的textrank_id的网络那样绘制textrank_sentences的输出?

library(udpipe)
tagger <- udpipe_load_model(tagger$file_model)
joboffer <- udpipe_annotate(tagger, job_rawtxt)
joboffer <- as.data.frame(joboffer)
joboffer$textrank_id <- unique_identifier(joboffer, c("doc_id","paragraph_id", "sentence_id"))
sentences <- unique(joboffer[, c("textrank_id", "sentence")])
terminology <- subset(joboffer, upos %in% c("NOUN", "ADJ"))
terminology <- terminology[, c("textrank_id", "lemma")]
tr <- textrank_sentences(data = sentences, terminology = terminology)

0 个答案:

没有答案