Find answers from the community

A
Ariel
Offline, last seen 16 hours ago
Joined February 5, 2025
A
Ariel
·

Checkpoint

I'm currently developing an agent workflow with human in the loop interaction and function calling. The workflow works great if the user stays in the session to complete it. I've tried both context serialization and checkpoints in order to persist context state with no success. I save the context/checkpoint after each iteration and load it back when starting the workflow as suggested in the documentation. I think the problem is with tool calling. Right after loading the checkpoint and adding the new user input, the agent gets stuck "thinking" ... as if it didn't know what steps is next.
5 comments
L
A
Hello all! I've managed to build an AgentWorkflow with human in the loop support. The workflow works great, the only thing I'm not able to achieve is streaming text down to the client. I'm using the suggested approach:
Plain Text
async for event in handler.stream_events():
        if isinstance(event, AgentStream):
            message = ChatMessage(role="bot", type="delta", content=event.delta)
            await websocket.send_json(message.model_dump())
...

The message sent to the client always have an empty delta. I'm using OpenAI with streaming set to true, is there anything I'm missing?
10 comments
L
A