rm print statements

This commit is contained in:
Lorenze Jay
2025-01-27 15:13:52 -08:00
parent ac28f7f4bc
commit 42769e8b22
3 changed files with 0 additions and 8 deletions

View File

@@ -41,7 +41,6 @@ class BaseFileKnowledgeSource(BaseKnowledgeSource, ABC):
def model_post_init(self, _):
"""Post-initialization method to load content."""
print("model_post_init")
self.safe_file_paths = self._process_file_paths()
self.validate_content()
self.content = self.load_content()
@@ -71,7 +70,6 @@ class BaseFileKnowledgeSource(BaseKnowledgeSource, ABC):
def _save_documents(self):
"""Save the documents to the storage."""
if self.storage:
print("saving source documents to storage")
self.storage.save(self.chunks)
else:
raise ValueError("No storage found to save documents.")

View File

@@ -46,9 +46,7 @@ class BaseKnowledgeSource(BaseModel, ABC):
Save the documents to the storage.
This method should be called after the chunks and embeddings are generated.
"""
print("saving documents", self.storage)
if self.storage:
print("storage found")
self.storage.save(self.chunks)
else:
raise ValueError("No storage found to save documents.")

View File

@@ -101,7 +101,6 @@ class KnowledgeStorage(BaseKnowledgeStorage):
self.collection = self.app.get_or_create_collection(
name=collection_name, embedding_function=self.embedder
)
print("db initialized", self.collection)
else:
raise Exception("Vector Database Client not initialized")
except Exception:
@@ -195,11 +194,8 @@ class KnowledgeStorage(BaseKnowledgeStorage):
embedder_config (Optional[Dict[str, Any]]): Configuration dictionary for the embedder.
If None or empty, defaults to the default embedding function.
"""
print("embedder", embedder)
self.embedder = (
EmbeddingConfigurator().configure_embedder(embedder)
if embedder
else self._create_default_embedding_function()
)
print("self.embedder", self.embedder)
print("type of self.embedder", type(self.embedder))