Fix long ingestion and Qdrant compatibility
This commit is contained in:
@@ -154,7 +154,8 @@ async def ingest_library(library_id: str, name: str, description: Optional[str]
|
||||
# Embed chunks and prepare for storage
|
||||
print(f" Chunked into {len(chunks)} pieces (approx. {num_tokens} tokens)")
|
||||
|
||||
embeddings = embed_texts(chunks)
|
||||
# FastEmbed is synchronous and CPU-heavy; keep it off the API event loop.
|
||||
embeddings = await asyncio.to_thread(embed_texts, chunks)
|
||||
|
||||
# Build chunk dicts
|
||||
chunk_dicts = []
|
||||
|
||||
Reference in New Issue
Block a user