Cache markdown render output per message part

This commit is contained in:
Shantur Rathore
2025-10-28 14:41:09 +00:00
parent 6597783e85
commit d18e44f721
6 changed files with 140 additions and 63 deletions

View File

@@ -1,3 +1,8 @@
export interface RenderCache {
text: string
html: string
}
export interface MessageDisplayParts {
text: any[]
tool: any[]
@@ -17,3 +22,11 @@ export interface Message {
version: number
displayParts?: MessageDisplayParts
}
export interface TextPart {
id?: string
type: "text"
text: string
synthetic?: boolean
renderCache?: RenderCache
}