Update embeddings integration for new batch embeddings interfaces (#669)

* Fix vector extraction

* Fix embeddings integration
This commit is contained in:
cybermaggedon 2026-03-08 19:41:52 +00:00 committed by GitHub
parent 0a2ce47a88
commit 919b760c05
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 55 additions and 56 deletions

View file

@ -67,8 +67,7 @@ class Processor(FlowProcessor):
)
# vectors[0] is the vector set for the first (only) text
# vectors[0][0] is the first vector in that set
vectors = resp.vectors[0][0] if resp.vectors else []
vectors = resp.vectors[0] if resp.vectors else []
embeds = [
ChunkEmbeddings(

View file

@ -72,7 +72,7 @@ class Processor(FlowProcessor):
entities = [
EntityEmbeddings(
entity=entity.entity,
vectors=vectors[0], # First vector from the set
vectors=vectors, # Vector set for this entity
chunk_id=entity.chunk_id, # Provenance: source chunk
)
for entity, vectors in zip(v.entities, all_vectors)

View file

@ -216,7 +216,7 @@ class Processor(CollectionConfigHandler, FlowProcessor):
index_name=index_name,
index_value=index_value,
text=text,
vectors=vectors[0] # First vector from the set
vectors=vectors # Vector set for this text
)
)