Spaces:
Runtime error
Runtime error
Commit
Β·
dd426a1
1
Parent(s):
ee33bad
add punkt tokenizer
Browse files
app.py
CHANGED
@@ -120,6 +120,7 @@ def find_source(text, docs):
|
|
120 |
@st.experimental_singleton
|
121 |
def init_models():
|
122 |
nltk.download('stopwords')
|
|
|
123 |
from nltk.corpus import stopwords
|
124 |
stop = set(stopwords.words('english') + list(string.punctuation))
|
125 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
|
|
120 |
@st.experimental_singleton
|
121 |
def init_models():
|
122 |
nltk.download('stopwords')
|
123 |
+
nltk.download('punkt')
|
124 |
from nltk.corpus import stopwords
|
125 |
stop = set(stopwords.words('english') + list(string.punctuation))
|
126 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|