(sessionId: string, history: MessageData[])
| 25 | } |
| 26 | |
| 27 | async function saveHistory(sessionId: string, history: MessageData[]) { |
| 28 | historyStore[sessionId] = history; |
| 29 | } |
| 30 | |
| 31 | // Define the Zod schemas for the expected output |
| 32 | const DynamicComponentSchema = z.object({ |