Spaces:
Runtime error
Runtime error
Update helpers.py
Browse files- helpers.py +3 -1
helpers.py
CHANGED
@@ -294,7 +294,9 @@ def get_json_splits_only(file_path):
|
|
294 |
return table_splits
|
295 |
|
296 |
def list_docx_files(folder_path):
|
297 |
-
|
|
|
|
|
298 |
|
299 |
def prompt_order(queries):
|
300 |
text = 'IMPORTANT: Here is the questions of user in order, use that and the context above to know the best answer:\n'
|
|
|
294 |
return table_splits
|
295 |
|
296 |
def list_docx_files(folder_path):
|
297 |
+
"""List all DOCX and DOC files in the given folder (including subfolders)."""
|
298 |
+
return [str(file) for file in Path(folder_path).rglob("*.docx")] + \
|
299 |
+
[str(file) for file in Path(folder_path).rglob("*.doc")]
|
300 |
|
301 |
def prompt_order(queries):
|
302 |
text = 'IMPORTANT: Here is the questions of user in order, use that and the context above to know the best answer:\n'
|