Skip to content

Commit 9af5cb5

Browse files
authored
separate config for preprocessing config on kb create (#67)
1 parent bbfbf5d commit 9af5cb5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

minds/knowledge_bases/knowledge_bases.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ class KnowledgeBaseConfig(BaseModel):
2626
description: str
2727
vector_store_config: Optional[VectorStoreConfig] = None
2828
embedding_config: Optional[EmbeddingConfig] = None
29+
preprocessing_config: Optional[PreprocessingConfig] = None
2930
# Params to apply to retrieval pipeline.
3031
params: Optional[Dict] = None
3132

@@ -129,6 +130,8 @@ def create(self, config: KnowledgeBaseConfig) -> KnowledgeBase:
129130
if config.embedding_config.params is not None:
130131
embedding_data.update(config.embedding_config.params)
131132
create_request['embedding_model'] = embedding_data
133+
if config.preprocessing_config is not None:
134+
create_request['preprocessing'] = config.preprocessing_config.model_dump()
132135
if config.params is not None:
133136
create_request['params'] = config.params
134137

0 commit comments

Comments
 (0)