Skip to content

Commit c319374

Browse files
Erez Sharimasaf
authored andcommitted
fix: static agent
fixes an issue with the static agent where the first message wasn't seen, until after a refresh
1 parent 2b01cd0 commit c319374

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

examples/static/static_agent.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,10 @@ async def run(self, context: Context, deps: Deps) -> bool:
5050
)
5151
await asyncio.sleep(1.5)
5252

53+
await deps.event_emitter.enqueue_status_event(
54+
correlation_id=deps.correlator.correlation_id,
55+
data=StatusEventData(type="status", status="typing"),
56+
)
5357
# create a chunk event to send a response, we can stream multiple chunks for the same event id
5458
event_id = EventId(uuid.uuid4().hex)
5559
cec = ChunkEvent(

0 commit comments

Comments
 (0)