dump from state_as_dict when state is a pydantic model

This commit is contained in:
Markus Ecker
2025-03-18 17:38:30 +01:00
parent 7ec56e3c55
commit 8c66caed1b
+1 -1
View File
@@ -156,7 +156,7 @@ async def copilotkit_emit_state(state: Any) -> Literal[True]:
run_id=execution["run_id"],
active=True,
role="assistant",
state=json.dumps(state),
state=json.dumps(state_as_dict),
running=True
)
)