Spaces:
Running
Running
jaifar530
commited on
fic words_counts
Browse files
app.py
CHANGED
@@ -48,7 +48,10 @@ with open('RandomForestClassifier.pkl', 'rb') as file:
|
|
48 |
|
49 |
|
50 |
input_paragraph = st.text_area("Input your text here")
|
51 |
-
|
|
|
|
|
|
|
52 |
|
53 |
# df = pd.DataFrame(columns=["paragraph"])
|
54 |
# df = df.append({"paragraph": input_paragraph}, ignore_index=True)
|
|
|
48 |
|
49 |
|
50 |
input_paragraph = st.text_area("Input your text here")
|
51 |
+
words_counts = word_tokenize(input_paragraph)
|
52 |
+
st.write('Words counts: ', sum(len(words_count) for words_count in words_counts))
|
53 |
+
|
54 |
+
|
55 |
|
56 |
# df = pd.DataFrame(columns=["paragraph"])
|
57 |
# df = df.append({"paragraph": input_paragraph}, ignore_index=True)
|