Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python: ChromaMemoryStore - Get methods will default to not return embeddings in query results #7563

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ async def upsert_batch(self, collection_name: str, records: list[MemoryRecord])
# upsert is checking collection existence
return [await self.upsert(collection_name, record) for record in records]

async def get(self, collection_name: str, key: str, with_embedding: bool) -> MemoryRecord:
async def get(self, collection_name: str, key: str, with_embedding: bool = False) -> MemoryRecord:
"""Gets a record.

Args:
Expand All @@ -200,7 +200,12 @@ async def get(self, collection_name: str, key: str, with_embedding: bool) -> Mem
f"Record with key '{key}' does not exist in collection '{collection_name}'"
) from exc

async def get_batch(self, collection_name: str, keys: list[str], with_embeddings: bool) -> list[MemoryRecord]:
async def get_batch(
self,
collection_name: str,
keys: list[str],
with_embeddings: bool = False
) -> list[MemoryRecord]:
"""Gets a batch of records.

Args:
Expand Down
Loading