Skip to content

Commit 9d25b94

Browse files
committed
Remove comments
1 parent 7530206 commit 9d25b94

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

app/main.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# Main giga kox file
21
import streamlit as st
32
import time
43
from src.file_processor import FileProcessor
@@ -10,9 +9,6 @@ def main():
109
st.session_state.tests_run = False
1110

1211
if not st.session_state.tests_run:
13-
# test_http.test_port()
14-
# test_file_ext.test_file_ext("manu.txt")
15-
# test_file_ext.test_file_ext("manu.pdf")
1612
st.session_state.tests_run = True
1713

1814
st.title("Kaka - AI powered document summary")
@@ -49,7 +45,6 @@ def main():
4945
st.session_state.submitted = False
5046

5147
if file is not None and not st.session_state.submitted:
52-
# test_file.test_file_name(file)
5348
if st.button("Summarize"):
5449
st.session_state.submitted = True
5550
st.rerun()

app/src/file_processor.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
1-
# Support for various file formats
21
import streamlit as st
32
import os
43
from typing import Optional
54
from docx import Document
65
import fitz
7-
#from tests import test_file_ext
86

97
class FileProcessor:
108
def __init__(self):
@@ -31,7 +29,7 @@ def upload_file(self) -> None:
3129

3230
def _read_txt(self) -> str:
3331
return self.file.getvalue().decode("utf-8")
34-
32+
3533
def _read_docx(self) -> str:
3634
doc = Document(self.file)
3735
text = []
@@ -45,7 +43,7 @@ def _read_pdf(self) -> str:
4543
for page in doc:
4644
text += page.get_text()
4745
return text
48-
46+
4947

5048
def get_content(self) -> Optional[str]:
5149
if not self.file:

0 commit comments

Comments
 (0)