-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
checkpoint: add DuckDB store #2154
Conversation
…langgraph into vb/add-duckdb-checkpointer
) | ||
) | ||
|
||
if PutOp in grouped_ops: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we worried about race conditions?
We have write operations mixed with read operations?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mm, that's a good question. don't think we're currently calling them together anywhere, but it's probably good to avoid that -- i can add a warning?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this exposed to end users?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes but we're not showing that anywhere in the docs. i.e. the APIs that are actually meant to be used are .put()
/ .search()
/ .get
, which just call .batch()
under the hood
) -> list[tuple[str, Sequence]]: | ||
inserts: list[PutOp] = [] | ||
deletes: list[PutOp] = [] | ||
for _, op in put_ops: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see this was copied over from the Postgres implementation.
I'm wondering if there's a scenario where breaking the ordering of DELETE
and INSERT
in the original list of put_ops
causes an issue.
This method accepts an arbitrary list of put_ops
and returns a reordered list of queries.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think this is a valid concern, kind of related to Eugene's questions above. i think we'll need to rethink this a bit for both postgres and duckdb, but for now all of the publicly documented methods that we show in the docs are single ops https://github.com/langchain-ai/langgraph/blob/main/libs/checkpoint/langgraph/store/base/__init__.py#L260
No description provided.