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

[FEAT] LangGraph support via Zep checkpointer #342

Open
elvenking opened this issue Jun 9, 2024 · 9 comments
Open

[FEAT] LangGraph support via Zep checkpointer #342

elvenking opened this issue Jun 9, 2024 · 9 comments
Labels
enhancement New feature or request

Comments

@elvenking
Copy link

I am implementing a multi-agent AI backend using LangChain, LangServe and LangGraph. I would like to store graph state in Zep with similar DX as is currently for chat message history

I would like to have support for a LangGraph state persistence in Zep and have Zep implementation of a LangGraph's checkpointer (ZepSaver) class

https://langchain-ai.github.io/langgraph/reference/checkpoints/

Since LangGraph is a recommended way how to build chat agents in LangChain, i believe this functionality would be helpful to many.

@danielchalef danielchalef added the enhancement New feature or request label Jun 18, 2024
@albeiroespitia
Copy link

Did you manage to implement this?

@TechNickAI
Copy link

If you try to pass the ZepChatMessageHistory, you get an error

instance of BaseCheckpointSaver expected (type=type_error.arbitrary_type; expected_arbitrary_type=BaseCheckpointSaver)

Seems like we need a ZepCheckpointSaver

@elvenking
Copy link
Author

@albeiroespitia No, i am migrating to LangGraph Cloud when it become available.

@danielchalef
Copy link
Member

Thanks, all. We'd love to support LangGraph. LG checkpoints contain both chat history and the graph's state. Would you expect Zep to maintain state for the entire graph?

How should Zep's more advanced features - Facts, Dialog Classification, Structured Data Extraction - feature in a LangGraph integration?

@albeiroespitia
Copy link

albeiroespitia commented Jul 19, 2024

@danielchalef I really wanted to try the facts feature in my langgraph app, I ended up extracting the facts myself with a custom llm, it would be great to have a zep checkpointer in the future that supports all of these features.

@elvenking
Copy link
Author

elvenking commented Jul 20, 2024

@danielchalef
At this point LangGraph Cloud trying to be one stop shop for all your LangGraph needs (deployment + persistent state storage).

What i would ideally like to have is an option to choose Zep (imagined with LangGraph capabilities) to store my graph state and use LangGraph Cloud only for deployment, advanced observability and evaluation. I hope community will push them in that direction, so we could use Zep with LangGraph Cloud. This would be true for any other popular data storage in AI field i would say.

Maybe ping @hwchase17 about that ?

@danielchalef
Copy link
Member

@elvenking I expect LangChain to continue rapidly evolving and enhancing the LangGraph framework and cloud service in the coming year, with changes to APIs and the Checkpoint format inevitable. I want to avoid replicating the great work LangChain is doing (and not get caught chasing API changes). We're considering how we can best add value to the ecosystem. I've reached out to you on email. Hope to learn more about your use case & challenges.

@joaomorossini
Copy link

I'm interested in this enhancement as well. After using Zep and following its development for a while now, I've come to think it's the best solution for memory so far. Making it compatible with LangGraph would be very useful.

Meanwhile, perhaps there's a workaround: Would it be possible to use ZepMemory as a part of the state instead of being itself the state? Any thoughts?, @elvenking @danielchalef @albeiroespitia

@danielchalef
Copy link
Member

Hi all - thanks for raising this again. At this time, we won't be developing a LangGraph Checkpointer. We recently published an example of using Zep's Facts alongside chat history stored in LangGraph state for context: https://github.com/getzep/zep-python/blob/main/examples/langgraph-agent/agent.ipynb

Hopefully, this offers a path to you all.

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

No branches or pull requests

5 participants