| 109 | return data |
| 110 | |
| 111 | class HTMLReader(Reader): |
| 112 | def parse(self, file_path: Path) -> str: |
| 113 | logger.info(f"Reading HTML file from {file_path}.") |
| 114 | with open(file_path, "r") as f: |
| 115 | data = BeautifulSoup(f, "html.parser") |
| 116 | text = data.get_text() |
| 117 | return text |
| 118 | |
| 119 | class MarkdownReader(Reader): |
| 120 | def parse(self, file_path: Path) -> str: |