Stateful, provider-agnostic markup stripper for one transcript segment.
Fed text chunk-by-chunk, it returns the user-visible text and accumulates the stripped
tags. A tag-shaped trailing fragment (a partial <... arriving split across chunks) is
held back until it closes, so a tag straddling a chunk boundary is never emitted
half-stripped. Shared by the transcript sinks (room output + transcript synchronizer) so
stripping and expression extraction stay identical across them.
Stateful, provider-agnostic markup stripper for one transcript segment.
Fed text chunk-by-chunk, it returns the user-visible text and accumulates the stripped tags. A tag-shaped trailing fragment (a partial
<...arriving split across chunks) is held back until it closes, so a tag straddling a chunk boundary is never emitted half-stripped. Shared by the transcript sinks (room output + transcript synchronizer) so stripping and expression extraction stay identical across them.