From d0780d6c3816d971a1e9d835ebd84fdc2faf8c6f Mon Sep 17 00:00:00 2001 From: latifboubyan Date: Thu, 28 Nov 2024 11:27:43 +0300 Subject: [PATCH] use correct embed parameter --- .../components/embedders/ollama/document_embedder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/integrations/ollama/src/haystack_integrations/components/embedders/ollama/document_embedder.py b/integrations/ollama/src/haystack_integrations/components/embedders/ollama/document_embedder.py index 4a16fd449..baebe7a02 100644 --- a/integrations/ollama/src/haystack_integrations/components/embedders/ollama/document_embedder.py +++ b/integrations/ollama/src/haystack_integrations/components/embedders/ollama/document_embedder.py @@ -101,7 +101,7 @@ def _embed_batch( range(0, len(texts_to_embed), batch_size), disable=not self.progress_bar, desc="Calculating embeddings" ): batch = texts_to_embed[i : i + batch_size] - result = self._client.embed(model=self.model, prompt=batch, options=generation_kwargs) + result = self._client.embed(model=self.model, input=batch, options=generation_kwargs) all_embeddings.extend(result["embeddings"]) meta["model"] = self.model