| 21 | } |
| 22 | |
| 23 | export interface Message { |
| 24 | role: 'user' | 'assistant' | 'simulated_assistant' | 'system' |
| 25 | content: string |
| 26 | timestamp: string |
| 27 | attachments?: MessageAttachment[] |
| 28 | /** If the backend returned an error for this message */ |
| 29 | error?: MessageError |
| 30 | /** True while waiting for the backend response */ |
| 31 | isLoading?: boolean |
| 32 | /** Reasoning summaries from model thinking (e.g. OpenAI reasoning tokens) */ |
| 33 | reasoningSummaries?: string[] |
| 34 | /** |
| 35 | * Original text content before conversion. Only set when it differs |
| 36 | * from `content` (which holds the converted value). |
| 37 | */ |
| 38 | originalContent?: string |
| 39 | /** Original media attachments before conversion (when different from converted). */ |
| 40 | originalAttachments?: MessageAttachment[] |
| 41 | } |
| 42 | |
| 43 | export interface MessageError { |
| 44 | type: string // e.g. 'blocked', 'processing', 'empty', 'unknown' |
nothing calls this directly
no outgoing calls
no test coverage detected