UNPKG

@adonis-agora/agent

Version:

Governed, durable-backed AI agent (chat + tool-calling + governance) for AdonisJS — part of the Agora ecosystem.

22 lines • 869 B
import type { AgentBackend } from '../backend.js'; /** * What changed about a backend's thread list. `changed` → refetch (a thread was created, or a run * settled and the server wrote its title); `title` → the stream announced a title, patch in place. */ export type ThreadsEvent = { type: 'changed'; } | { type: 'title'; threadId: string; title: string; } | { type: 'removed'; threadId: string; }; type Listener = (event: ThreadsEvent) => void; /** Tell every {@link useThreads} on `backend` that its list moved. */ export declare function notifyThreads(backend: AgentBackend, event: ThreadsEvent): void; /** Subscribe to {@link notifyThreads} for `backend`; returns the unsubscribe. */ export declare function onThreadsEvent(backend: AgentBackend, listener: Listener): () => void; export {}; //# sourceMappingURL=threads-events.d.ts.map