export function buildChatMarkdown(messages: unknown[], assistantName: string): string | null { const history = Array.isArray(messages) ? messages : []; if (history.length === 0) { returnnull;
} const lines: string[] = [`# Chat with ${assistantName}`, ""]; for (const msg of history) { const m = msg as Record<string, unknown>; const role = m.role === "user" ? "You" : m.role === "assistant" ? assistantName : "Tool"; const content = extractTextCached(msg) ?? ""; const ts = typeof m.timestamp === "number" ? new Date(m.timestamp).toISOString() : "";
lines.push(`## ${role}${ts ? ` (${ts})` : ""}`, "", content, "");
} return lines.join("\n");
}
Messung V0.5 in Prozent
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.12Bemerkung:
(vorverarbeitet am 2026-09-28)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.