Skip to content

Commit

Permalink
rm score when filtering docs
Browse files Browse the repository at this point in the history
  • Loading branch information
anakin87 committed Dec 19, 2023
1 parent 89ca25c commit 542ec80
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions integrations/pinecone/src/pinecone_haystack/document_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,8 @@ def filter_documents(self, filters: Optional[Dict[str, Any]] = None) -> List[Doc
if not filters:
# in this case, we try to return all documents but Pinecone has some limits
documents = self._embedding_retrieval(query_embedding=self._dummy_vector, top_k=TOP_K_LIMIT)
for doc in documents:
doc.score = None

total_docs_number = self.count_documents()
if total_docs_number > TOP_K_LIMIT:
Expand Down

0 comments on commit 542ec80

Please sign in to comment.