mirror of
https://github.com/langchain-ai/memory-template.git
synced 2026-07-19 12:51:24 -04:00
HTTPStatusError("Client error '422 Unprocessable Entity' ... #3
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @wkdghdus on GitHub (Oct 17, 2024).
Hi, there are some issues trying to implement this template to the project I am working on.
When I import this project straight into my project without any modification, it returns such error.
There is no problem running the memory state separately, and I've figured that it is a problem with get_client() not being able to run in the background. I've tried inputting url parameter as http://localhost:8123, yet the error changes to ConnectError('All connection attempts failed') but does not fix.
what possibly could happen here? All I did was to copy paste the code into my repository, changed the import to absolute path, and all the models to openAI. the same code works perfectly in the template.
@wkdghdus commented on GitHub (Oct 17, 2024):
I've been trying to run the template using langgraph up and the debugger. but it seems like the memory isn't updating when I use this method. It runs perfectly on the desktop CLI. But when I use the debugger and langgraph up command I get this error, resulting in memories not getting updated
@wkdghdus commented on GitHub (Oct 17, 2024):
I've solved this problem by modifying langgraph.json file.
I've initially assigned the graph names like these
"convo/chatBot": "path/to/chatbot/graph.py:graph"
"convo/memoryGraph": path/to/memory/graph.py:graph"
I think this for some reason hindered the ability for get_client to fetch the memory graph.
(I have no idea how get_client() fetches the correct graph without any specification)
but when I changed the graph names to "chatBot" "memoryGraph", it worked as intended.
can somebody possibly explain why this solution worked?
@hinthornw commented on GitHub (Nov 14, 2024):
It's https://github.com/langchain-ai/memory-template/blob/141b1b0afff40b5cea79212b9fa5cc9be58f26ef/src/chatbot/configuration.py#L17
the assistant ID configuration value can etiher be a graph name or an assistant.