ReplaySource
Loads a thread's AG-UI protocol events from the server, in the order a live stream delivered them, so a session can rebuild the thread as the live view showed it.
Return the events as a promise of an array or as an observable that
completes. Resolve to an empty array when the server has nothing for the
thread; reject, or error, for any other failure. signal aborts when the
session is disposed.
import type { ReplaySource } from '@threadplane/ag-ui';Declaration
export type ReplaySource = (threadId: string, signal: AbortSignal) => Promise<readonly BaseEvent[]> | ReplaySubscribable;