定义于: activities/chat/stream/strategies.ts:34
批量策略 - 每 N 个块发出一次。 适用于降低 UI 更新频率
new BatchStrategy(batchSize): BatchStrategy;
定义于: activities/chat/stream/strategies.ts:37
number = 5
BatchStrategy
reset(): void;
定义于: activities/chat/stream/strategies.ts:48
可选: 重置策略状态 (在流式传输开始时调用)
void
shouldEmit(_chunk, _accumulated): boolean;
定义于: activities/chat/stream/strategies.ts:39
在接收到每个文本块时调用
string
string
boolean
如果现在应该发出更新,则为 true