Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -58,14 +58,14 @@ def process_file(file):
|
|
58 |
return "Unsupported file type."
|
59 |
|
60 |
st.title("File Reader")
|
61 |
-
user = st.text_input("Input Text to Redact")
|
62 |
uploaded_file = st.file_uploader("Upload a file", type=["pdf", "docx", "txt"])
|
63 |
-
if(user != ''):
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
if uploaded_file is not None:
|
70 |
file_contents = process_file(uploaded_file)
|
71 |
token = sentence_tokenize(file_contents)
|
|
|
58 |
return "Unsupported file type."
|
59 |
|
60 |
st.title("File Reader")
|
61 |
+
# user = st.text_input("Input Text to Redact")
|
62 |
uploaded_file = st.file_uploader("Upload a file", type=["pdf", "docx", "txt"])
|
63 |
+
# if(user != ''):
|
64 |
+
# token = sentence_tokenize(user)
|
65 |
+
# final=''
|
66 |
+
# for i in range(0, len(token)):
|
67 |
+
# final+=mask_generation(token[i])+'\n'
|
68 |
+
# st.text_area("OUTPUT",final,height=400)
|
69 |
if uploaded_file is not None:
|
70 |
file_contents = process_file(uploaded_file)
|
71 |
token = sentence_tokenize(file_contents)
|