vinni1484 commited on
Commit
39c0fbb
·
1 Parent(s): deb1ba4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -4,8 +4,8 @@ from keybert import KeyBERT
4
  model = KeyBERT("sentence-transformers/xlm-r-distilroberta-base-paraphrase-v1")
5
 
6
  def keywords(text):
7
- keywords = model.extract_keywords(text,keyphrase_ngram_range=(1,2),top_n=10)
8
  keywords = dict(keywords)
9
  return keywords
10
 
11
- gr.Interface(keywords, "text", "text",title="Keyword Extractor").launch()
 
4
  model = KeyBERT("sentence-transformers/xlm-r-distilroberta-base-paraphrase-v1")
5
 
6
  def keywords(text):
7
+ keywords = model.extract_keywords(text, keyphrase_ngram_range=(1,2), top_n=10)
8
  keywords = dict(keywords)
9
  return keywords
10
 
11
+ gr.Interface(keywords, "text", "text", title="Keyword Extractor").launch()