Skip to content

Commit

Permalink
Fixing datastore limitation indexing large fields in metadata (#582)
Browse files Browse the repository at this point in the history
  • Loading branch information
lspataroG authored Nov 14, 2024
1 parent 611c59a commit 61856e6
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -294,8 +294,12 @@ def mset(self, key_value_pairs: Sequence[Tuple[str, Document]]) -> None:
entity = self._client.entity(
key=key, exclude_from_indexes=self.exclude_from_indexes
)
metadata_entity = self._client.entity(
exclude_from_indexes=self.exclude_from_indexes
)
metadata_entity.update(document.metadata)
entity[self._text_property_name] = document.page_content
entity[self._metadata_property_name] = document.metadata
entity[self._metadata_property_name] = metadata_entity
entities.append(entity)

self._client.put_multi(entities)
Expand Down

0 comments on commit 61856e6

Please sign in to comment.