tweak: delimit consecutive queued user messages

Minor: newline between consecutive user messages in batch.
Clearer separation when inputs queue.
This commit is contained in:
d190038fccab24ea 2025-12-01 11:52:48 +00:00
parent b1b82977ec
commit 20b74b8401
No known key found for this signature in database
GPG key ID: DFAEB15C0E474F55

View file

@ -565,7 +565,7 @@ export namespace MessageV2 {
const userMessage: UIMessage = {
id: msg.info.id,
role: "user",
parts: [],
parts: result.at(-1)?.role === "user" ? [{ type: "text", text: "\n" }] : [],
}
result.push(userMessage)
for (const part of msg.parts) {