Skip to content

Commit d1d770d

Browse files
committed
chore: fix issue with the embedding transformation
1 parent f7b2010 commit d1d770d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/common/search/vectorSearchEmbeddingsManager.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -285,9 +285,9 @@ export class VectorSearchEmbeddingsManager {
285285
const adaptedEmbeddings = providerEmbeddings.map((embeddings) => {
286286
// now map based on the sample embeddings
287287
if (Array.isArray(sampleEmbeddings) && Array.isArray(embeddings)) {
288-
return providerEmbeddings;
288+
return embeddings;
289289
}
290-
if (sampleEmbeddings instanceof BSON.Binary && Array.isArray(providerEmbeddings)) {
290+
if (sampleEmbeddings instanceof BSON.Binary && Array.isArray(embeddings)) {
291291
if (this.matches(() => sampleEmbeddings.toBits())) {
292292
return BSON.Binary.fromBits(embeddings);
293293
}

0 commit comments

Comments
 (0)