Currently OnTextEndFunc receives only the message ID:
OnTextEndFunc func(id string) error
Consumers who need the full accumulated text (e.g., to collect or persist completed messages) must buffer all deltas themselves. This duplicates the internal activeTextContent map already maintained by the agent.
OnReasoningEndFunc already passes the full content:
OnReasoningEndFunc func(id string, reasoning ReasoningContent) error
Proposal: add the accumulated text as a second parameter:
OnTextEndFunc func(id string, text string) error
The text is already available at the call site from activeTextContent[part.ID].
Currently
OnTextEndFuncreceives only the message ID:Consumers who need the full accumulated text (e.g., to collect or persist completed messages) must buffer all deltas themselves. This duplicates the internal
activeTextContentmap already maintained by the agent.OnReasoningEndFuncalready passes the full content:Proposal: add the accumulated text as a second parameter:
The text is already available at the call site from
activeTextContent[part.ID].