ag-ui-protocol / ag-ui-protocol/ag-ui

@ag-ui/client - textMessageBuffer not populated when emitting events directly

未關閉
#888 1 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
bug SDK
主要語言
Python
星號
15.9k
分支
1.4k
平均合併
1 天 17 小時
30 天內合併 PR
163

描述

When extending AbstractAgent and emitting TEXT_MESSAGE_* events directly via the subscriber (not through HttpAgent with a server), the textMessageBuffer parameter passed to onTextMessageContentEvent is empty/undefined.

This appears to be because textMessageBuffer is computed by defaultApplyEvents which looks up the message content in the managed messages array. When events are emitted directly without going through defaultApplyEvents, no message objects are created, so the buffer lookup fails.

Questions:

Is this the intended behavior?
Should AbstractAgent maintain its own text buffer for direct event emission use cases?
Should the documentation clarify that textMessageBuffer only works when using the built-in event processing pipeline?

As a workaround I am manually accumulating deltas in an onEvent handler

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。