Skip to content

Commit

Permalink
await async_get_embeddings_with_backoff (#239)
Browse files Browse the repository at this point in the history
  • Loading branch information
vivi authored Nov 1, 2023
1 parent a269ffd commit 8a3724c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion memgpt/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ def insert(self, memory_string, embedding=None):
async def a_insert(self, memory_string, embedding=None):
if embedding is None:
# Get the embedding
embedding = async_get_embedding_with_backoff(memory_string, model=self.embedding_model)
embedding = await async_get_embedding_with_backoff(memory_string, model=self.embedding_model)
return self._insert(memory_string, embedding)

def _search(self, query_embedding, query_string, count=None, start=None):
Expand Down

0 comments on commit 8a3724c

Please sign in to comment.