Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
✨ support .md
Browse filesSigned-off-by: peter szemraj <peterszemraj@gmail.com>
app.py
CHANGED
@@ -205,7 +205,7 @@ def load_single_example_text(
|
|
205 |
global name_to_path
|
206 |
full_ex_path = name_to_path[example_path]
|
207 |
full_ex_path = Path(full_ex_path)
|
208 |
-
if full_ex_path.suffix
|
209 |
with open(full_ex_path, "r", encoding="utf-8", errors="ignore") as f:
|
210 |
raw_text = f.read()
|
211 |
text = clean(raw_text, lower=False)
|
|
|
205 |
global name_to_path
|
206 |
full_ex_path = name_to_path[example_path]
|
207 |
full_ex_path = Path(full_ex_path)
|
208 |
+
if full_ex_path.suffix in [".txt", ".md"]:
|
209 |
with open(full_ex_path, "r", encoding="utf-8", errors="ignore") as f:
|
210 |
raw_text = f.read()
|
211 |
text = clean(raw_text, lower=False)
|