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

Implement immediate persistence (possibly with gokv) #84

Open
codefromthecrypt opened this issue May 21, 2024 · 1 comment
Open

Implement immediate persistence (possibly with gokv) #84

codefromthecrypt opened this issue May 21, 2024 · 1 comment

Comments

@codefromthecrypt
Copy link
Contributor

I ran into this comment on langchaingo and while hinted on the roadmap, might be nice to have an issue to subscribe to.

Perhaps an experimental implementation could be co-raised as a PR here and a draft PR on langchaingo for integration.

@philippgille
Copy link
Owner

  • Regarding gokv integration: I'd prefer to wait for the next version, in which we want to add the typical context.Context param to the Set/Get/Delete methods. There is some ongoing work already in that direction.
  • Regarding langchain-go integration (without gokv support): I actually have a draft PR locally with the implementation itself and example code (in their example directory), but the unit tests are still missing.

I think both integrations can be implemented separately at first, and later they can be combined. I don't want to tie people to any specific implementation, so the way I envision this is to (re-)declare the gokv interface here in chromem-go (to avoid the dependency on gokv), and have a constructor similar to the current NewPersistentDB, where users can inject whichever gokv implementation they want to use, or provide their own implementation of the simple interface. And in langchain-go we can then also add a separate constructor which calls this aforementioned chromem-go constructor, so users can in the same way inject any gokv implementation they want to use.

I'll update this thread when there's progress on one of the two points.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants