Patch Changes
-
#2083
48eeba7Thanks @cjol! - DefineVoiceTurnContext.messagesas completed history before the current transcript for both text and audio turns, preventing duplicate user messages when following the documented prompt construction.Existing
onTurn()implementations:- If you pass
context.messagesdirectly as the complete LLM input, appendtranscriptexactly once. - If you already append
transcripttocontext.messages, no change is required. - Direct
getConversationHistory()calls insideonTurn()continue to include the current transcript.
- If you pass
-
#2004
0efd545Thanks @cjol! - Pass the fullkeytermsarray to Workers AI Flux and Nova-3 STT instead of only the first term. -
#2049
ce0e608Thanks @cjol! - Preserve spacing between streamed text segments separated by tool calls. Think messenger delivery and Voice now share the same boundary-aware text joining logic fromagents/chat.Existing users must:
- Replace imports of
textDeltaFromStreamChunk()from@cloudflare/think/messengerswithTextStreamCallback, passing it the complete structured stream events. - Upgrade to
agents@0.21.0when installing@cloudflare/think@0.16.0or@cloudflare/voice@0.3.6; both now requireagents >=0.20.2. - Update exact-text expectations if they relied on segments around tool calls being concatenated without a space.
- Replace imports of