bupa1018 commited on
Commit
7f71568
·
1 Parent(s): 466808a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -77,7 +77,7 @@ def download_gitlab_repo():
77
 
78
  # Check if the file already exists in the repository
79
  existing_files = api.list_repo_files(repo_id=HF_SPACE_NAME, repo_type='space')
80
- target_path = f"{REPOSITORY_DIRECTORY}/{filename}"
81
 
82
  print(f"Target Path: '{target_path}'")
83
  print(f"Existing Files: {[repr(file) for file in existing_files]}")
@@ -386,9 +386,9 @@ def initialize():
386
  doc_file_paths = ['docs/source/usage/lib.rst']
387
 
388
 
389
- #code_files, code_file_references = process_directory(REPOSITORY_DIRECTORY, code_partial_paths, code_file_path)
390
 
391
- doc_files, doc_file_references = process_directory(REPOSITORY_DIRECTORY, doc_partial_paths, doc_file_paths)
392
 
393
  #code_chunks = split_pythoncode_into_chunks(code_files, code_file_references, 1500, 0)
394
  doc_chunks = split_into_chunks(doc_files, doc_file_references, CHUNK_SIZE, CHUNK_OVERLAP)
 
77
 
78
  # Check if the file already exists in the repository
79
  existing_files = api.list_repo_files(repo_id=HF_SPACE_NAME, repo_type='space')
80
+ target_path = f"{DATA_DIR}/{filename}"
81
 
82
  print(f"Target Path: '{target_path}'")
83
  print(f"Existing Files: {[repr(file) for file in existing_files]}")
 
386
  doc_file_paths = ['docs/source/usage/lib.rst']
387
 
388
 
389
+ #code_files, code_file_references = process_directory(DATA_DIR, code_partial_paths, code_file_path)
390
 
391
+ doc_files, doc_file_references = process_directory(DATA_DIR, doc_partial_paths, doc_file_paths)
392
 
393
  #code_chunks = split_pythoncode_into_chunks(code_files, code_file_references, 1500, 0)
394
  doc_chunks = split_into_chunks(doc_files, doc_file_references, CHUNK_SIZE, CHUNK_OVERLAP)