bupa1018 commited on
Commit
55462ca
·
1 Parent(s): 713932a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -5
app.py CHANGED
@@ -171,8 +171,6 @@ def process_directory(directory, folder_paths, file_paths):
171
 
172
  # Add this snippet after the 'all_texts.append(text)' and 'file_references.append(file_path)' lines.
173
 
174
- print(f"The length of all_texts is: {len(all_texts)}")
175
-
176
 
177
  return all_texts, file_references
178
 
@@ -341,8 +339,6 @@ def split_pythoncode_into_chunks(texts, references, chunk_size, chunk_overlap):
341
  for chunk in file_chunks:
342
  document = Document(page_content=chunk, metadata={"source": reference})
343
  chunks.append(document)
344
-
345
- print(f"Total number of chunks: {len(chunks)}")
346
  return chunks
347
 
348
 
@@ -353,7 +349,6 @@ def split_into_chunks(texts, references, chunk_size, chunk_overlap):
353
 
354
  for text, reference in zip(texts, references):
355
  chunks.extend([Document(page_content=chunk, metadata={"source": reference}) for chunk in text_splitter.split_text(text)])
356
- print(f"Total number of chunks: {len(chunks)}")
357
  return chunks
358
 
359
  # Setup Vectorstore
 
171
 
172
  # Add this snippet after the 'all_texts.append(text)' and 'file_references.append(file_path)' lines.
173
 
 
 
174
 
175
  return all_texts, file_references
176
 
 
339
  for chunk in file_chunks:
340
  document = Document(page_content=chunk, metadata={"source": reference})
341
  chunks.append(document)
 
 
342
  return chunks
343
 
344
 
 
349
 
350
  for text, reference in zip(texts, references):
351
  chunks.extend([Document(page_content=chunk, metadata={"source": reference}) for chunk in text_splitter.split_text(text)])
 
352
  return chunks
353
 
354
  # Setup Vectorstore