mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-09-14 05:31:40 +00:00
chore(model): Modify siliconflow name (#2194)
This commit is contained in:
@@ -506,6 +506,7 @@ class Service(BaseService[KnowledgeSpaceEntity, SpaceServeRequest, SpaceServeRes
|
||||
name=space.name,
|
||||
embedding_fn=embedding_fn,
|
||||
max_chunks_once_load=CFG.KNOWLEDGE_MAX_CHUNKS_ONCE_LOAD,
|
||||
max_threads=CFG.KNOWLEDGE_MAX_THREADS,
|
||||
llm_client=self.llm_client,
|
||||
model_name=None,
|
||||
)
|
||||
@@ -567,6 +568,10 @@ class Service(BaseService[KnowledgeSpaceEntity, SpaceServeRequest, SpaceServeRes
|
||||
doc.chunk_size = len(chunk_docs)
|
||||
vector_ids = [chunk.chunk_id for chunk in chunk_docs]
|
||||
else:
|
||||
max_chunks_once_load = (
|
||||
vector_store_connector._index_store_config.max_chunks_once_load
|
||||
)
|
||||
max_threads = vector_store_connector._index_store_config.max_threads
|
||||
assembler = await EmbeddingAssembler.aload_from_knowledge(
|
||||
knowledge=knowledge,
|
||||
index_store=vector_store_connector.index_client,
|
||||
@@ -575,7 +580,10 @@ class Service(BaseService[KnowledgeSpaceEntity, SpaceServeRequest, SpaceServeRes
|
||||
|
||||
chunk_docs = assembler.get_chunks()
|
||||
doc.chunk_size = len(chunk_docs)
|
||||
vector_ids = await assembler.apersist()
|
||||
vector_ids = await assembler.apersist(
|
||||
max_chunks_once_load=max_chunks_once_load,
|
||||
max_threads=max_threads,
|
||||
)
|
||||
doc.status = SyncStatus.FINISHED.name
|
||||
doc.result = "document persist into index store success"
|
||||
if vector_ids is not None:
|
||||
|
Reference in New Issue
Block a user