Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -43,7 +43,7 @@ def tokenization(text):
|
|
| 43 |
df['tokenized_clean_msg'] = df['clean_msg'].apply(lambda x: tokenization(x))
|
| 44 |
# Remove stopwords
|
| 45 |
from nltk.corpus import stopwords
|
| 46 |
-
|
| 47 |
|
| 48 |
def remove_stopwords(text):
|
| 49 |
output = [word for word in text if word not in stopwords]
|
|
|
|
| 43 |
df['tokenized_clean_msg'] = df['clean_msg'].apply(lambda x: tokenization(x))
|
| 44 |
# Remove stopwords
|
| 45 |
from nltk.corpus import stopwords
|
| 46 |
+
stop_words = set(nltk.corpus.stopwords.words('english'))
|
| 47 |
|
| 48 |
def remove_stopwords(text):
|
| 49 |
output = [word for word in text if word not in stopwords]
|