浏览代码

fix: do not use hardware ID in document ID generation

Aarni Koskela 1 年之前
父节点
当前提交
61bb1f1dc8
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      backend/apps/rag/main.py

+ 1 - 1
backend/apps/rag/main.py

@@ -622,7 +622,7 @@ def store_docs_in_vector_db(docs, collection_name, overwrite: bool = False) -> b
 
         for batch in create_batches(
             api=CHROMA_CLIENT,
-            ids=[str(uuid.uuid1()) for _ in texts],
+            ids=[str(uuid.uuid4()) for _ in texts],
             metadatas=metadatas,
             embeddings=embeddings,
             documents=texts,