-
Notifications
You must be signed in to change notification settings - Fork 17
Closed
Description
version: langgraph-checkpoint-redis 0.1.0
I run the graph using the following method.
async for node, , event_data in graph.astream(
input=input,
config=config,
stream_mode=["messages", "updates"],
subgraphs=True,
)
The first time I send a message {"role": "user", "content": "hello"} it works fine, but when I send a second message with the same thread_id, it throws this error.
Message dict must contain 'role' and 'content' keys, got {'lc': 1, 'type': 'constructor', 'id': ['langchain', 'schema', 'messages', 'HumanMessage'], 'kwargs': {'content': 'nihao1111', 'type': 'human', 'id': '85e627b6-aba8-468d-9b8a-0552a66f2e68'}}
For troubleshooting, visit: https://python.langchain.com/docs/troubleshooting/errors/MESSAGE_COERCION_FAILURE
Metadata
Metadata
Assignees
Labels
No labels